ILocation::SetDesiredAccuracy method (locationapi.h)
[The Win32 Location API is available for use in the operating systems specified in the Requirements section. It may be altered or unavailable in subsequent versions. Instead, use the Windows.Devices.Geolocation API. ]
Specifies the accuracy to be used.
Syntax
HRESULT SetDesiredAccuracy(
[in] REFIID reportType,
[in] LOCATION_DESIRED_ACCURACY desiredAccuracy
);
Parameters
[in] reportType
REFIID that specifies the report type for which to set the accuracy to be used.
[in] desiredAccuracy
LOCATION_DESIRED_ACCURACY value that specifies the accuracy to be used.
Return value
The method returns an HRESULT. Possible values include, but are not limited to, those in the following table.
Return code | Description |
---|---|
|
The method succeeded. |
|
reportType was other than IID_ILatLongReport or IID_ICivicAddressReport. |
|
The value of desiredAccuracy is not supported in the LOCATION_DESIRED_ACCURACY enumerated type. |
Requirements
Requirement | Value |
---|---|
Minimum supported client | Windows 7 [desktop apps only] |
Minimum supported server | None supported |
Target Platform | Windows |
Header | locationapi.h |
DLL | LocationAPI.dll |