MapExtensions.OpenAsync Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Overloads
OpenAsync(IMap, Location) |
Open the installed application to a specific location. |
OpenAsync(IMap, Placemark) |
Open the installed application to a specific placemark. |
OpenAsync(IMap, Location, MapLaunchOptions) |
Open the installed application to a specific location with launch options. |
OpenAsync(IMap, Double, Double) |
Open the installed application to a specific location. |
OpenAsync(IMap, Location)
- Source:
- Map.shared.cs
- Source:
- Map.shared.cs
Open the installed application to a specific location.
public:
[System::Runtime::CompilerServices::Extension]
static System::Threading::Tasks::Task ^ OpenAsync(Microsoft::Maui::ApplicationModel::IMap ^ map, Microsoft::Maui::Devices::Sensors::Location ^ location);
public static System.Threading.Tasks.Task OpenAsync (this Microsoft.Maui.ApplicationModel.IMap map, Microsoft.Maui.Devices.Sensors.Location location);
static member OpenAsync : Microsoft.Maui.ApplicationModel.IMap * Microsoft.Maui.Devices.Sensors.Location -> System.Threading.Tasks.Task
<Extension()>
Public Function OpenAsync (map As IMap, location As Location) As Task
Parameters
- map
- IMap
The object this method is invoked on.
- location
- Location
Location to open in the map application.
Returns
A Task object with the current status of the asynchronous operation.
Applies to
OpenAsync(IMap, Placemark)
- Source:
- Map.shared.cs
- Source:
- Map.shared.cs
Open the installed application to a specific placemark.
public:
[System::Runtime::CompilerServices::Extension]
static System::Threading::Tasks::Task ^ OpenAsync(Microsoft::Maui::ApplicationModel::IMap ^ map, Microsoft::Maui::Devices::Sensors::Placemark ^ placemark);
public static System.Threading.Tasks.Task OpenAsync (this Microsoft.Maui.ApplicationModel.IMap map, Microsoft.Maui.Devices.Sensors.Placemark placemark);
static member OpenAsync : Microsoft.Maui.ApplicationModel.IMap * Microsoft.Maui.Devices.Sensors.Placemark -> System.Threading.Tasks.Task
<Extension()>
Public Function OpenAsync (map As IMap, placemark As Placemark) As Task
Parameters
- map
- IMap
The object this method is invoked on.
- placemark
- Placemark
Placemark to open in the map application.
Returns
A Task object with the current status of the asynchronous operation.
Applies to
OpenAsync(IMap, Location, MapLaunchOptions)
- Source:
- Map.shared.cs
- Source:
- Map.shared.cs
Open the installed application to a specific location with launch options.
public:
[System::Runtime::CompilerServices::Extension]
static System::Threading::Tasks::Task ^ OpenAsync(Microsoft::Maui::ApplicationModel::IMap ^ map, Microsoft::Maui::Devices::Sensors::Location ^ location, Microsoft::Maui::ApplicationModel::MapLaunchOptions ^ options);
public static System.Threading.Tasks.Task OpenAsync (this Microsoft.Maui.ApplicationModel.IMap map, Microsoft.Maui.Devices.Sensors.Location location, Microsoft.Maui.ApplicationModel.MapLaunchOptions options);
static member OpenAsync : Microsoft.Maui.ApplicationModel.IMap * Microsoft.Maui.Devices.Sensors.Location * Microsoft.Maui.ApplicationModel.MapLaunchOptions -> System.Threading.Tasks.Task
<Extension()>
Public Function OpenAsync (map As IMap, location As Location, options As MapLaunchOptions) As Task
Parameters
- map
- IMap
The object this method is invoked on.
- location
- Location
Location to open in the map application.
- options
- MapLaunchOptions
Launch options to use.
Returns
A Task object with the current status of the asynchronous operation.
Exceptions
Thrown when either location
or options
is null
.
Applies to
OpenAsync(IMap, Double, Double)
- Source:
- Map.shared.cs
- Source:
- Map.shared.cs
Open the installed application to a specific location.
public:
[System::Runtime::CompilerServices::Extension]
static System::Threading::Tasks::Task ^ OpenAsync(Microsoft::Maui::ApplicationModel::IMap ^ map, double latitude, double longitude);
public static System.Threading.Tasks.Task OpenAsync (this Microsoft.Maui.ApplicationModel.IMap map, double latitude, double longitude);
static member OpenAsync : Microsoft.Maui.ApplicationModel.IMap * double * double -> System.Threading.Tasks.Task
<Extension()>
Public Function OpenAsync (map As IMap, latitude As Double, longitude As Double) As Task
Parameters
- map
- IMap
The object this method is invoked on.
- latitude
- Double
Target latitude.
- longitude
- Double
Target longitude.
Returns
A Task object with the current status of the asynchronous operation.