Official Content

KML (formerly known as Keyhole Markup Language) is a standard XML-based format used to represent vector data.

When developing a Native Mobile application, if you include in a Panel object a Grid control with its Control Type property set to Maps, you can use the LoadKmlLayer method to draw a set of vector data from its representation in KML format.

When developing a Web application, if you include in a Web Panel object a Map User Control, you can set the KML property to true, and determine the URL where the KML will be loaded from the KMLURL property.

Considerations

The LoadKmlLayer method only allows displaying the content of a KML file.

There is no functionality to initialize a variable based on the Geography data type from a KML file. To achieve this, you have 2 possible options:

1) Convert the KML file to GeoJSON or WKT and, after that, initialize the attribute or variable of Geography data type using the FromGeoJSON method or the FromWkt method, respectively.
2) Run through the KML file with the XMLReader Data Type and populate a Geography attribute or variable for each coordinate.

Last update: March 2025 | © GeneXus. All rights reserved. GeneXus Powered by Globant