On Oct 20, 7:57 am, xelawho <[email protected]> wrote: > Hi, > > I have some polylines that are loaded from xml and get shown/hidden by > checking a checkbox. I put some arrowheads on them to indicate > directon, hoping that the arrows would appear when the line was shown > and dissapear when it was not. > > But that's not the case - the arrowheads appear permanently on the > map, regardless of if their relevant line is shown. > > Is there some way to bind the arrows to the line, so only the ones > that "belong" to that line get shown when the line does? > > Here's my map:http://xelawho.com/map/arrow.htm > > the lines get shown/hidden by clicking the Bus Routes boxes down the > bottom.
Your arrows are markers, you can show/hide markers just like you can polylines. There are lots of threads discussing how to do it. You need to keep an array of them and loop through it hiding or showing them depending upon whether or not the polyline is visible (you can use the same functions you use for the polylines just add a loop to show/hide the arrows. -- Larry > > thanks for your help, > > Lucas -- You received this message because you are subscribed to the Google Groups "Google Maps API V2" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/google-maps-api?hl=en.
