How to: Load Data from a KML File
To load data from a KML file, do the following.
- Create a KmlFileDataAdapter object and assign it to the VectorLayer.Data property.
- Specify the KmlFileDataAdapter.FileUri property of the object.
Note
Make sure that the Build Action property of a KML file is set to Resource.
Note
A complete sample project is available at https://github.com/DevExpress-Examples/how-to-display-kml-file-shapes-e4526.
<dxm:VectorLayer>
<dxm:KmlFileDataAdapter FileUri="kmlFile.kml" />
</dxm:VectorLayer>
See Also