Show / Hide Table of Contents

Constructor KmlDataset

KmlDataset(Uri)

Initializes a new instance of the KmlDataset class.

Declaration
public KmlDataset(Uri source)
Parameters
Type Name Description
System.Uri source

URI to a local or remote KML or KMZ file.

Remarks

KML content can be distributed as XML (.kml) or a zipped archive (.kmz) containing KML files and supporting resources. You can read .kml and .kmz files from disk or the network.

Exceptions
Type Condition
System.ArgumentNullException

source is null.

Applies to

Platforms and versions
TargetVersions
.NET Standard 2.0100.4 - 200.7
.NET100.13 - 200.7
.NET Windows100.13 - 200.7
.NET Android200.2 - 200.7
.NET iOS200.0 - 200.7
.NET Framework100.4 - 200.7
Xamarin.Android100.4 - 100.14
Xamarin.iOS100.4 - 100.15
UWP100.4 - 200.7
Relevant samples
Display KML network links: Display a file with a KML network link, including displaying any network link control messages at launch.
Identify KML features: Show a callout with formatted content for a KML feature.
List KML contents: List the contents of a KML file.

KmlDataset(KmlNode)

Initializes a new instance of the KmlDataset class, with the given KmlNode as its root node.

Declaration
public KmlDataset(KmlNode rootNode)
Parameters
Type Name Description
KmlNode rootNode

The KmlNode to use as the first root node.

Remarks

KML dataset is the source of KML information backing a KML layer. Use the KML dataset to interact with the contents of a KML layer. Licensing for KML depends on the method of access. Creating a KML dataset from a root node requires an ArcGIS Maps SDK for .NET 'Standard' license level.

Exceptions
Type Condition
System.ArgumentNullException

rootNode is null.

Applies to

Platforms and versions
TargetVersions
.NET Standard 2.0100.6 - 200.7
.NET100.13 - 200.7
.NET Windows100.13 - 200.7
.NET Android200.0 - 200.7
.NET iOS200.0 - 200.7
.NET Framework100.6 - 200.7
Xamarin.Android100.6 - 100.15
Xamarin.iOS100.6 - 100.15
UWP100.6 - 200.7
Relevant samples
Create and save KML file: Construct a KML document and save it as a KMZ file.
Edit KML ground overlay: Edit the values of a KML ground overlay.
In This Article
Back to top Copyright © 2022 Esri.