Last Updated: 18 Jun 2019 14:08 by ADMIN
Created on: 18 Jun 2019 07:34
Category: Map
Type: Feature Request
How to load an overlay image into the Map Control

I am wanting to load an image and polygon onto the Map control. I am using a KML file. I am able to load the polygon but NOT able to display the image in the map control.

i.e. if I open the KML file in google earth the image and polygon are displayed, I want to 'replicate' this in the Map control.


Below is my sample code and attached are the KML file and image files.


Dim osmProvider As New OpenStreetMapProvider()




        Me.RadMap1.Layers.Add(New MapLayer("Pens"))

        Using seatsStream As New FileStream("D:\MyTelerikMap\Farm.kml", FileMode.Open, FileAccess.Read)

            Dim elements As List(Of MapVisualElement) = KmlReader.Read(seatsStream)

            For Each item As MapVisualElement In elements

                item.BorderWidth = 1

                item.BorderColor = Color.Black

                item.BackColor = Color.Red



        End Using


        Dim MyCenter As PointG

        MyCenter.Latitude = -16.545276685809551

        MyCenter.Longitude = 28.87446081916244


        RadMap1.MapElement.BringIntoView(MyCenter, 16)


Thank you in advanced for your assistance.



Attached Files:
1 comment
Dess | Tech Support Engineer, Sr.
Posted on: 18 Jun 2019 14:08
Hello, Robin,          

The provided KML file is greatly appreciated. Indeed, Google Earth displays the KML file in a different way. I have reviewed the content of the file itself. 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 (partially)
6. ExtendedData
7. Partial support for MultiGeometry tag. 

"GroundOverlay" KML type is not supported in RadMap's KML readers. 

However, it seems to be a reasonable request.

I have logged it in our feedback portal by making this thread public. You can track its progress, subscribe for status changes and add your comments on the following link - feedback item.

I have also updated your Telerik points.

The easiest way that I can suggest in order to insert an image to RadMap is to use a custom pin with the desired image. You can refer to the following help article demonstrating how to achieve this requirement: https://docs.telerik.com/devtools/winforms/knowledge-base/radmap-pins-with-an-image

I hope this information helps. If you need any further assistance please don't hesitate to contact me. 
Dess | Tech Support Engineer, Sr.
Progress Telerik
Get quickly onboarded and successful with your Telerik and/or Kendo UI products with the Virtual Classroom free technical training, available to all active customers. Learn More.