This is a migrated thread and some comments may be shown as answers.

RadMap KML Support. What is and isnt supported ?

1 Answer 158 Views
Map
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Ian
Top achievements
Rank 1
Ian asked on 13 Mar 2012, 05:06 AM
Hi telerik.

So i have currently been given the task of letting users import lots of different kml into our radmap control,  and i am finding very mixed results, alot of them give errors.

I found an old post stating that only the following are currently supported
Currently the map control supports the following KML elements:
 1. Point
 2. LineString
 3. Polygon (including outerBoundaryIs and innerBoundaryIs)
 4. Styles: IconStyle (including hotspot), LineStyle, PolyStyle
 5. BalloonStyle
 6. ExtendedData
 7. Partial support for MultiGeometry tag.

Is this still true for today (using 2012 release). and is there a nice easy way to determine when im reading the kml if something is supported or not and show an error ?

 

if (dialog.File.Extension == ".kmz")

{

 

ZipFile zipFile = new ZipFile(dialog.File.OpenRead());

 

List<FrameworkElement> list = KmlReader.Read(zipFile.GetInputStream(0));

 

foreach (FrameworkElement element in list)

{

 

this.wmllayer.Items.Add(element);

}

 

this.wmllayer.Visibility = Visibility.Visible;

}

 

else

{

 

// Open the selected file to read.

System.IO.

 

Stream fileStream = dialog.File.OpenRead();

 

List<FrameworkElement> list = KmlReader.Read(fileStream);

 

foreach (FrameworkElement element in list)

{

 

this.wmllayer.Items.Add(element);

}

 

this.wmllayer.Visibility = Visibility.Visible;

}


Any help would be greatly appreciated

1 Answer, 1 is accepted

Sort by
0
Andrey
Telerik team
answered on 15 Mar 2012, 09:34 AM
Hello Ian,

Yes, it is true for the 2012.Q1 version. The list of the supported KML elements have not been changed. Unfortunately there is no way to detect unsupported KML elements in the current version of the RadMap control. We are planning to change it in the future. You can check when this feature will be available using our PITS:

http://www.telerik.com/support/pits.aspx#/public/silverlight/10203

Regards,
Andrey Murzov
the Telerik team
Sharpen your .NET Ninja skills! Attend Q1 webinar week and get a chance to win a license! Book your seat now >>
Tags
Map
Asked by
Ian
Top achievements
Rank 1
Answers by
Andrey
Telerik team
Share this question
or