Hi,

I've put some LatLng coordinates into an array and I'm having problems
accessing them. If I trace the latLngArray[0] in latLngCreator, it
outputs correctly.

But, in pointTester, I have a problem with latLngArray[0] in the line
pointInPolygon(latLngArray[0], outlinePolylineArray[0]);. If I replace
latLngArray[0] with latlngTester, it works fine. What is the correct
way to access a LatLng when it's in an array?


public function latLngCreator():void {
                latLngArray = [];
                var i:int;
                var arrayCollectionLength:int = ddData.length;
                for  (i=0; i < arrayCollectionLength; i++) {
                            ddLatLng = new LatLng(ddData[i].latitude, 
ddData[i].longitude);

                latLngArray.push(ddLatLng);
                //trace(latLngArray[0]);
                }



 public function pointTester():void {
                        //var latlngTester:LatLng= new LatLng(38.8630, 
-76.9513);

                var isPointInPolygon:Boolean = pointInPolygon(latLngArray
[0], outlinePolylineArray[0]);
            if (isPointInPolygon) {
                Alert.show("In poly!");
            } else {
                Alert.show("Not in poly!");
            }
        }

Thank you!

-Laxmidi
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Google Maps API For Flash" 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-for-flash?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to