On Nov 15, 7:06 pm, John M Phillips <johnm.phillips1...@gmail.com>
wrote:
> The term used is closure (which I do not fully understand),
> but I had to wrap the creation of each polyline inside of a
> function.  

Here is Mike Williams' explanation from his (v2) tutorial:
Javascript Concepts: Function Closure
http://econym.org.uk/gmap/closure.htm

  -- Larry


> See
>      http://www.jtphillips.com/cgi-bin/AtcInspectionForm.cgi
> and the function
>       addLineWithClosure
>
> Hope this example helps
>
> On Nov 15, 3:56 pm, Canam Group <canamgr...@gmail.com> wrote:
>
>
>
>
>
>
>
> > Yeah, very similar.
> > Actually, in my application (not the example I provided), when I
> > refresh my map (not the page, but an AJAX call to update markers and
> > polylines), it works the second time (and every time after that). I
> > have the problem only on the first load.
>
> > When I reload the whole page, only the last polyline is shown (but all
> > markers are still shown correctly).

-- 
You received this message because you are subscribed to the Google Groups 
"Google Maps JavaScript API v3" group.
To post to this group, send email to google-maps-js-api...@googlegroups.com.
To unsubscribe from this group, send email to 
google-maps-js-api-v3+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-maps-js-api-v3?hl=en.

Reply via email to