I'm getting the following error when loading a map in my web page and
placing markers on it.  I was wondering if anyone has seen this error
before.  I look like it's an issue in the API, but I wasn't sure.
Thank you for any help you can provide!!!!

Here's the error message:
-------------------------------------
Webpage Script Errors

User Agent: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1; Trident/
4.0; .NET CLR 1.1.4322; .NET CLR 2.0.50727; .NET CLR
3.0.04506.30; .NET CLR 3.0.04506.648)
Timestamp: Thu, 15 Jan 2009 23:44:37 UTC

Message: 'U' is null or not an object
Line: 608
Char: 39
Code: 0
URI: http://maps.google.com/intl/en_us/mapfiles/140g/maps2.api/main.js

And here is some of the Javascript code I'm using:
------------------------------------------------------------------------
** Note: I'm loading the data from an XML file I created using .NET.
I've verified the XML file is created before this code runs.  I had it
working previously using code very similar to this, with the exception
that I'm now pulling the latitude and longitude from the XML file and
creating a GLatLng object, as opposed to using the Geocoder to return
the coordinates.

        function GeocodeProperties()
        {
            var xmlFile = document.getElementById("TextFileName")

            xmlDoc.async = "false";
            xmlDoc.load("xml/" + xmlFile.value);

            var intPropertyCount = xmlDoc.getElementsByTagName("users")
[0].childNodes.length;

            if(geocoder)
            {
                for(var i = 0; i < intPropertyCount; i++)
                {
                    var latitude = "";
                    var longitude = "";

                    latitude = xmlDoc.getElementsByTagName("users")
[0].childNodes(i).getAttribute("latitude");
                    longitude = xmlDoc.getElementsByTagName("users")
[0].childNodes(i).getAttribute("longitude");

                    if((latitude != "") && (longitude != ""))
                    {
                        var point = new GLatLng(parseFloat(latitude),
parseFloat(longitude));
                        map.addOverlay(addPoint(point,
 
xmlDoc.getElementsByTagName("users")[0].childNodes(i).getAttribute
("id"),
 
xmlDoc.getElementsByTagName("users")[0].childNodes(i).getAttribute
("name"),
 
xmlDoc.getElementsByTagName("users")[0].childNodes(i).getAttribute
("address")));
                    }
                }
            }
        }

        function addPoint(point, userid, name, address)
        {
            var marker = new GMarker(point);
            alert(point.lat() + " - " + point.lng() + " - ID: " +
userid);

            GEvent.addListener( marker,
                                "click",
                                function()
                                {
                                    var myHtml = "<p
align='left'><font color='black' syle='font-family: Arial; font-size:
smaller;'>" +
                                                 "<strong>User ID: " +
userid + " - " + name + "</strong><br />" +
                                                 "Address: " + address
+ "</font></p>"
                                    map.openInfoWindowHtml(point,
myHtml);
                                });

            map.addOverlay(marker);
        }
    // ]]>

Thanks again!

Shawn

--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---

Reply via email to