public static void ToMap(double latitude, double longitude) { if (latitude > 90 || latitude < -90) { throw new ArgumentOutOfRangeException("Latitude has to be between -90 and 90."); } if (longitude > 180 || longitude < -180) { throw new ArgumentOutOfRangeException("Longitude has to be between -90 and 90."); } var window = new MapWindow(); MapWindowViewModel datacontext = window.DataContext as MapWindowViewModel; datacontext.CentralPoint = new DevExpress.Xpf.Map.GeoPoint(latitude, longitude); window.Show(); }
public static void ToMap() { var window = new MapWindow(); window.Show(); }