<esri:Map MapGesture="OnGesture" /> <-- your event handler private void OnGesture(object sender, Map.MapGestureEventArgs e) { if (e.Gesture == GestureType.Tap) { var vm = DataContext as IMyContractThatIsImplementedInViewModel; if (vm == null) // Check if current datacontext supports it. throw new UnsupportedDataContextException(); vm.DoMyViewModelStuff(e.MapPoint); // Call your VM without any external information. } }
Angemeldete Mitglieder können Beiträge verfassen, Updates folgen und mehr. Neu hier? Registriere ein kostenloses Konto.
Find useful guides, FAQs, and documents to help you navigate and make the most of Esri Community.