On May 10, 8:47 pm, ant <[email protected]> wrote: > Hi, > > Im having some trouble using openInfoWindowHtml as well as > openInfoWindow on a marker of either GMarker or LabeledMarker type. I > am testing code based on one of the google examples, but keep getting: > > Error: b is undefined > Source > File:http://maps.gstatic.com/intl/en_ALL/mapfiles/225b/maps2.api/main.js > Line: 306 > > When I click a marker. > > The page is available here:http://test.wtf.com.au/maps-zoom/map.html
I get: A Runtime Error has occured. Line: 10 Error: Expected identifier, string or number. on this line: for (var i in dataLayer) because dataLayer is undefined. In IE this is because IE adds an extra null member when there is an extra comma at the end of a series of objects. You are also using a setTimeout to call setupOfficeMarkers and the dataLayer might not have loaded yet... Once I got through that, I see an 'x' is null or not an object when I click on a custom icon. That error is because your icon is not completely defined. You haven't defined the infoWindowAnchor property: http://code.google.com/apis/maps/documentation/reference.html#GIcon.infoWindowAnchor The pixel coordinate relative to the top left corner of the icon image at which the info window is anchored to this icon. So the API doesn't know where to open the infoWindow... -- Larry > > Ive tried different objects, and read up on the functions but I cant > see what might be the cause. Is anyone able to point me in the right > direction? > > Thanks, > Ant > > -- > 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 > athttp://groups.google.com/group/google-maps-api?hl=en. -- 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.
