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

EmptyProvider problems

3 Answers 56 Views
Map
This is a migrated thread and some comments may be shown as answers.
Jason D
Top achievements
Rank 1
Veteran
Jason D asked on 16 Jan 2015, 12:25 AM
Our clients typically import data into our application using known coordinate systems, such as UTM. However, now we need to add support for unknown, arbitrary coordinate systems (we won't show an underlying basemap). I am struggling with this. My understanding is I should use an EmptyProvider and the EPSG900913Projection. I have several issues, but the first is the Center. In your Mercator (meters) example, the Center is set using meters:

Center="296247.258782387,426130.145788193"

However, when I create a blank project and set the Center using meters, the value contained in the center is still in decimal degrees:

moMap.Center = New Location(5643603, 2559429)

Printing moMap.Center shows the following:
{85.05112878,180}
    CalculationMethod: ""
    Description: ""
    Empty: {-Infinity,-Infinity}
    IsEmpty: False
    Latitude: 85.05112878
    Longitude: 180.0

What am I doing wrong? Once working, will all the other map methods and properties return values in meters instead of degrees, too?

3 Answers, 1 is accepted

Sort by
0
Petar Mladenov
Telerik team
answered on 20 Jan 2015, 11:13 AM
Hi Jason,

We are unable to reproduce the mentioned issue. When we set up blank project with just RadMap in it, setting the Center to the mentioned value ("296247.258782387,426130.145788193") works as expected. Please check out our test project and let us know the part we are missing from your scenario.

Regards,
Petar Mladenov
Telerik
 

Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

 
0
Jason D
Top achievements
Rank 1
Veteran
answered on 20 Jan 2015, 06:33 PM
Ok, I got it working. It was a stupid mistake on my part.

Is this correct: If I supply my own provider with its projection set to EPSG900913Projection, I don't need to supply an EmptyProvider?

And: If I don't supply a custom provider, but want to use the VisualizationLayer, I must add an EmptyProvider?
0
Accepted
Petar Mladenov
Telerik team
answered on 23 Jan 2015, 09:51 AM
Hi Jason,

Yes if you add your own custom provider , you won't need Empty Provider. If you don't add your own provider, empty provider is almost mandatory  It provides definitions and methods which can be used to calculate positions of the framework elements, map shapes and pin points.

Regards,
Petar Mladenov
Telerik
 

Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

 
Tags
Map
Asked by
Jason D
Top achievements
Rank 1
Veteran
Answers by
Petar Mladenov
Telerik team
Jason D
Top achievements
Rank 1
Veteran
Share this question
or