New to Telerik UI for Xamarin? Download free 30-day trial


RadMap provides the following commands of type ICommand:

  • ZoomInCommand
  • ZoomOutCommand

You could manually call these commands, for example on button click action, to update the zoom level of the shapes displayed in RadMap.

Following is a quick example on how the commands of the Map control can be used.

Let's have the following Map definition:

<telerikMap:RadMap x:Name="map" MinZoomLevel="2" MaxZoomLevel="5">
                <telerikMap:MapShapeReader x:Name="reader"/>

where the Source of the MapShapeReader is defined like this:

var assembly = this.GetType().Assembly;
var source = MapSource.FromResource("", assembly);
this.reader.Source = source;

Lastly, use the following snippet to add two buttons that will execute the Map commands:

<Button Text="Zoom In" Command="{Binding Source={x:Reference map}, Path=ZoomInCommand}"/>
<Button Text="Zoom Out" Command="{Binding Source={x:Reference map}, Path=ZoomOutCommand}"/>

See Also

In this article
Not finding the help you need? Improve this article