How to limit the area/location I want to view in GMap.Net WPF using c#?
Asked Answered
B

0

2

I have this code that shows specific location I needed on my project.

public partial class ViewLocation : Window
{
    public ViewLocation()
    {
        InitializeComponent();
    }

    private void gmap_Loaded(object sender, RoutedEventArgs e)
    {
        gmap.MapProvider = GMap.NET.MapProviders.GoogleMapProvider.Instance;
        gmap.Position = new GMap.NET.PointLatLng(13.4107591, 121.1764547);
        //gmap.SetPositionByKeywords("Calapan, Philippines");
        gmap.MinZoom = 13;
        gmap.MaxZoom = 18;
        gmap.Zoom = 9;
    }

}

But I have to limit the area that it shows. For example, I only want to see areas that are 2 miles away from my position. Is it possible to do? And how should I do it?

Bipolar answered 24/9, 2017 at 8:10 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.