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

Map Modes with Custom Provider

1 Answer 76 Views
This is a migrated thread and some comments may be shown as answers.
Top achievements
Rank 1
Esther asked on 21 Jun 2012, 03:53 PM

I have created a custom provider with my own tiles. 
Now,I´d like to create three map modes with different tiles. (Roal, Aerial.. as Bing or Google)
I want to show my modes on the toolbar so the user could change view easily.
How can I do that? I have no idea where I have to indicate the different modes. I have my TilesProvides created like that
Public Sub New(ByVal tileLocation As String, ByVal tileUri As String)
        Dim source As New NavteqMapSource(tileLocation, tileUri)
        Me.MapSources.Add(source.UniqueId, source)
    End Sub

But I need three different Uris for each MapMode. Do I have to create three different providers? 
If so, How can I add this providers to the toolBar?
Thank you very much,


1 Answer, 1 is accepted

Sort by
Telerik team
answered on 26 Jun 2012, 09:49 AM
Hi Esther,

You have to create 3 map sources: 1 for every mode. It can be done the same way as we did for the OpenStreet map provider. Your company has source codes of the RadControls, so I would recommend you to take a look to the following classes:

1. OpenStreetMapProvider (Controls\DataVisualization\Map\Providers\Map\OpenStreet\OpenStreetMapProvider.cs)
2. OsmTileMapSource(Controls\DataVisualization\Map\Providers\Map\OpenStreet\OsmTileMapSource.cs)
3. OpenStreetMapnikSource(Controls\DataVisualization\Map\Providers\Map\OpenStreet\OpenStreetMapnikSource.cs)
4. OpenStreetOsmarenderSource(Controls\DataVisualization\Map\Providers\Map\OpenStreet\OpenStreetOsmarenderSource.cs)

All the best,
Andrey Murzov
the Telerik team

Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>

Asked by
Top achievements
Rank 1
Answers by
Telerik team
Share this question