IMbnPinManager::GetPin method (mbnapi.h)

Important

Starting in Windows 10, version 1803, the Win32 APIs described in this section are replaced by the Windows Runtime APIs in the Windows.Networking.Connectivity namespace.

Gets a specific type of PIN.

Syntax

HRESULT GetPin(
  [in]          MBN_PIN_TYPE pinType,
  [out, retval] IMbnPin      **pin
);

Parameters

[in] pinType

An MBN_PIN_TYPE value that represents the requested PIN type.

[out, retval] pin

Pointer to the address of the IMbnPin for the requested PIN type. If this method returns any value other than S_OK, this parameter is NULL. Otherwise, the calling application must release this interface when it is done using it.

Return value

This method can return one of these values.

Return code Description
S_OK
The method completed successfully.
E_PENDING
The PIN type is not available. The Mobile Broadband service is currently probing the device to retrieve this information. When the PIN type is available, the Mobile Broadband service will call the OnPinListAvailable method of IMbnPinManagerEvents.
E_MBN_PIN_REQUIRED
A PIN is required for the operation to complete. The calling Application can retry this operation when device is PIN unlocked
E_MBN_SIM_NOT_INSERTED
There is no SIM in the device.
E_MBN_BAD_SIM
There is a bad SIM in the device.
HRESULT_FROM_WIN32(ERROR_NOT_SUPPORTED)
The requested PIN type is not supported by the device.

Requirements

Requirement Value
Minimum supported client Windows 7 [desktop apps | UWP apps]
Minimum supported server None supported
Target Platform Windows
Header mbnapi.h

See also

IMbnPinManager