SetPassword (coredll)
Last changed: -64.199.116.42

.
Summary
This function sets the system password.

C# Signature:

[System.Runtime.InteropServices.DllImportAttribute("coredll", EntryPoint = "SetPassword")]

[return: System.Runtime.InteropServices.MarshalAsAttribute(System.Runtime.InteropServices.UnmanagedType.Bool)]

public static extern bool SetPassword([System.Runtime.InteropServices.MarshalAsAttribute(System.Runtime.InteropServices.UnmanagedType.LPWStr)] System.Text.StringBuilder lpszOldPassword, [System.Runtime.InteropServices.MarshalAsAttribute(System.Runtime.InteropServices.UnmanagedType.LPWStr)] System.Text.StringBuilder lpszNewPassword);

VB Signature:

<System.Runtime.InteropServices.DllImportAttribute("coredll", EntryPoint := "SetPassword")> _

Public Shared Function SetPassword(<System.Runtime.InteropServices.MarshalAsAttribute(System.Runtime.InteropServices.UnmanagedType.LPWStr)> lpszOldPassword As System.Text.StringBuilder,<System.Runtime.InteropServices.MarshalAsAttribute(System.Runtime.InteropServices.UnmanagedType.LPWStr)> lpszNewPassword As System.Text.StringBuilder) As<System.Runtime.InteropServices.MarshalAsAttribute(System.Runtime.InteropServices.UnmanagedType.Bool)> Boolean!!!!User-Defined Types:

None.

Alternative Managed API:

Do you know one? Please contribute it!

Notes:

For a system starting with no password, pass null in for the lpszOldPassword parameter.

Tips & Tricks:

Please add some!

Sample Code:

Please add some!

Documentation