Share via


SimUnlockPhone

Send Feedback

The SimUnlockPhone function sends a password to unlock the phone. This function is part of the SIM Manager API set that enables access to information stored on the SIM card.

HRESULT SimUnlockPhone (
  HSIM hSim,
  LPTSTR lpszPassword,
  LPTSTR lpszNewPin
);

Parameters

  • hSim
    Points to a valid HSIM handle.
  • lpszPassword
    Points to a password string.
  • lpszNewPin
    Points to a second password string. Some locked states require a second password. for example, a pointer to an unknown (PUK) requires a new PIN to replace the old, presumably forgotten, PIN. The values can be NULL.

Return Values

HRESULTs are either S_OK for success, or one of the SIM_E error constants defined in the SIM Manager Error Constants table.

Remarks

This is a privileged function.

Requirements

Smartphone: Smartphone 2002 and later
Pocket PC: Pocket PC 2002 and later
OS Versions: Windows CE 3.0 and later
Header: simmgr.h
Library: cellcore.lib

See Also

SIMLOCKINGPWDLENGTH

Send Feedback on this topic to the authors

Feedback FAQs

© 2006 Microsoft Corporation. All rights reserved.