You might want to use the libkml developed by Pam Fox of Google (and others). It is at http://code.google.com/p/libkml/. There is also a link to a simple demo at that site. For a more robust discussion of using this with KML files that contain polystyles and other information, you can go to http://tnatlas2.geog.utk.edu/tutorhome. Chapter 5 of that tutorial is about using the libkml.
Bruce Ralston On Fri, Jul 8, 2011 at 1:40 PM, jijo <[email protected]> wrote: > Can someone tell me how to import a multiple polygon KML file into > Google Maps using flex code? > kml file is located on remote server and has multiple placemarks. > var retxml:XML = XML(event.result); > var retDoc:XMLDocument = new > XMLDocument(retxml); > var decoder:SimpleXMLDecoder = new > SimpleXMLDecoder(true); > var resultObj:Object = > decoder.decodeXML(retDoc); > //var resultTag_Polygon:String = > > resultObj.kml.Document.Placemark.MultiGeometry.Polygon.outerBoundaryIs.LinearRing.coordinates; > var resultTag_Polygon:String = > resultObj.kml.Document.Placemark.name.description; > Alert.show("resultTag_Polygon:" + > resultTag_Polygon ); > something like this....but its not working. > > -- > 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. > > -- Bruce Ralston Professor Emeritus Department of Geography University of Tennessee Knoxville, TN 37996-0925 Phone: 865-974-6043 FAX: 865-974-6025 -- 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.
