IPosNav::CloseDevice

This method closes a Positioning and Navigation device.

Syntax

HRESULT CloseDevice( hPNDevice hPN, );

Parameters

hPN
Handle to the Positioning and Navigation device to be closed

Return Values

One of the values described in the following table is returned.

Value
Description
S_OK Success
E_FAIL An unspecified error occurred.
E_INVALIDARG One or more arguments are invalid.
PNAPI_E_DEVICEUNAVAILABLE The Positioning and Navigation device is unavailable; it could be unplugged or dead.
PNAPI_E_MEMFREE The memory or resource cannot be freed.

Remarks

If this method is not called upon exiting, position and navigation API (PNAPI) resources are not deleted.

This method must wait for pending calls to finish before stopping calls to a Positioning and Navigation device. It may pause briefly before returning.

See Also

IPosNav::OpenDevice