Sorry, I put it wrong, changed to
var marker = createMarker(point, name, address, type);
map.addOverlay(marker);
marker.hide();
and now it works, Thanks for your input.
/Claus
On Sep 4, 11:36 pm, CQR <[EMAIL PROTECTED]> wrote:
> I'm using GMarker
> and have tryed to add the marker.hide like this
>
> function createMarker(point, name, address, type) {
> var marker = new GMarker(point, customIcons[type]);
> markerGroups[type].push(marker);
> marker.hide();
>
> but that dosent work
>
> /Claus
>
> On Sep 4, 11:15 pm, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]>
> wrote:
>
>
>
> > On Sep 4, 6:16 am, CQR <[EMAIL PROTECTED]> wrote:
>
> > > My Google map includes markers that is loaded from a xml file, with
> > > check boxes to hide and show theses markers, then I load the xml file
> > > all the markers is visible but I want then not to show up before the
> > > checkbox is checked, for that I have tried to add a function to with
> > > “marker.hide()” is also hides all the markers except for the last
> > > marker in the xml file, so my conclusion is that my function works,
> > > but maybe placed or called at the wrong time.
> > > Can anyone help me to find a
> > > solution.http://www.houseinchiangmai.net/test/map.asp?lat=18.800500&lng=98.957528
>
> > Hide it when you create it:
> > var marker = createMarker(point, name, address, type);
> > map.addOverlay(marker);
> > marker.hide();
> > -- Larry- Hide quoted text -
>
> - Show quoted text -
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Google Maps API" 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
-~----------~----~----~----~------~----~------~--~---