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

Zoom to highlighted shapes

2 Answers 49 Views
Map
This is a migrated thread and some comments may be shown as answers.
Luke
Top achievements
Rank 1
Luke asked on 13 Apr 2015, 12:19 PM

Hello - I run a simple system that looks at Sales orders, then with their associated country, changes the colour of that country on a map - pretty simple stuff.

 

Having that list of countries (shapes), is there a way to zoom so that they act as the zoom limits ie if only UK orders, only UK would be shown via zoom, or if UK and Australia, the map would center somewhere between the two, and zoom accordingly

 

Many thanks

2 Answers, 1 is accepted

Sort by
0
Accepted
Todor
Telerik team
answered on 16 Apr 2015, 06:49 AM
Hello Luke,

You need to set the best view of the RadMap by a given LocationRect object. You can see how to achieve that in this help article. The same technique is applicable in Visualization Layer as well. In addition you can check the 'How to set the best view for the information layer' demo in our SDK repository on gitHub.

For your convenience, I've created a sample project which uses the Visualization Layer and follows the above described approach. You can find the demo attached. 

I hope this helps.

Regards,
Todor
Telerik
 

See What's Next in App Development. Register for TelerikNEXT.

 
0
Luke
Top achievements
Rank 1
answered on 16 Apr 2015, 07:47 AM
Just the job - many thanks
Tags
Map
Asked by
Luke
Top achievements
Rank 1
Answers by
Todor
Telerik team
Luke
Top achievements
Rank 1
Share this question
or