Sdílet prostřednictvím


MapControl.TryGetLocationFromOffset Method

Definition

Overloads

TryGetLocationFromOffset(Point, AltitudeReferenceSystem, Geopoint)

Converts a point on the map to a geographic location by using the specified altitude reference system.

TryGetLocationFromOffset(Point, Geopoint)

Converts a point on the map to a geographic location.

TryGetLocationFromOffset(Point, AltitudeReferenceSystem, Geopoint)

Converts a point on the map to a geographic location by using the specified altitude reference system.

public:
 virtual bool TryGetLocationFromOffset(Point offset, AltitudeReferenceSystem desiredReferenceSystem, [Out] Geopoint ^ & location) = TryGetLocationFromOffset;
/// [Windows.Foundation.Metadata.Overload("TryGetLocationFromOffsetWithReferenceSystem")]
bool TryGetLocationFromOffset(Point const& offset, AltitudeReferenceSystem const& desiredReferenceSystem, [Out] Geopoint const& & location);
[Windows.Foundation.Metadata.Overload("TryGetLocationFromOffsetWithReferenceSystem")]
public bool TryGetLocationFromOffset(Point offset, AltitudeReferenceSystem desiredReferenceSystem, out Geopoint location);
Public Function TryGetLocationFromOffset (offset As Point, desiredReferenceSystem As AltitudeReferenceSystem, ByRef location As Geopoint) As Boolean

Parameters

offset
Point

A point on the map to convert to a geographic location.

desiredReferenceSystem
AltitudeReferenceSystem

The altitude reference system of the geographic point. A value of Unspecified for the altitude reference system has the same effect as using the default TryGetLocationFromOffset(Windows.Foundation.Point offset, Windows.Devices.Geolocation.Geopoint location) overload.

location
Geopoint

When this method returns, contains the corresponding geographic location.

Returns

Boolean

bool

Returns true if the location is invalid; otherwise, false.

Attributes

Windows requirements

Device family
Windows 10 Fall Creators Update (introduced in 10.0.16299.0)
API contract
Windows.Foundation.UniversalApiContract (introduced in v5.0)

Remarks

Use this method instead of the GetLocationFromOffset method. The GetLocationFromOffset method has been deprecated.

Applies to

TryGetLocationFromOffset(Point, Geopoint)

Converts a point on the map to a geographic location.

public:
 virtual bool TryGetLocationFromOffset(Point offset, [Out] Geopoint ^ & location) = TryGetLocationFromOffset;
/// [Windows.Foundation.Metadata.Overload("TryGetLocationFromOffset")]
bool TryGetLocationFromOffset(Point const& offset, [Out] Geopoint const& & location);
[Windows.Foundation.Metadata.Overload("TryGetLocationFromOffset")]
public bool TryGetLocationFromOffset(Point offset, out Geopoint location);
Public Function TryGetLocationFromOffset (offset As Point, ByRef location As Geopoint) As Boolean

Parameters

offset
Point

A point on the map to convert to a geographic location.

location
Geopoint

When this method returns, contains the corresponding geographic location.

Returns

Boolean

bool

Returns true if the location is invalid; otherwise, false.

Attributes

Windows requirements

Device family
Windows 10 Fall Creators Update (introduced in 10.0.16299.0)
API contract
Windows.Foundation.UniversalApiContract (introduced in v5.0)

Remarks

Use this method instead of the GetLocationFromOffset method. The GetLocationFromOffset method has been deprecated.

Applies to