<< Click to Display Table of Contents >> Navigation: WinLicense > WinLicense SDK > Miscellaneous Functions > WLHardwareGetID |
The WLHardwareGetID retrieves the current hardware ID for the current machine. This function should be used to retrieve the hardware ID in a machine to create license keys that are locked to a specific machine.
bool WLHardwareGetID ( char* pHardwareId); |
function WLHardwareGetID ( pHardwareId:PAnsiChar ):Boolean; stdcall; |
Public Declare Function WLHardwareGetID Lib "WinLicenseSDK.dll" ( ByVal pHardwareId As String ) As Boolean |
[C#] [DllImport(WINLICENSE_SDK_DLL, CallingConvention = CallingConvention.StdCall)] public static extern bool WLHardwareGetID(StringBuilder HardwareId);
[Visual Basic] <DllImport("WinlicenseSDK.dll", CallingConvention:=CallingConvention.StdCall)> Public Shared Function WLHardwareGetID(ByRef HardwareId As String) As Boolean End Function |
Parameters
pHardwareId
[out] Pointer to a buffer that will receive a null-terminated string with the hardware ID for the current machine.
Return Values
If the function succeeds, the return value is True.
If the function fails, the return value is False.
Remarks
The format of the hardware ID in the current implementation of WinLicense is as follows:
XXXX-XXXX-XXXX-XXXX-XXXX-XXXX-XXXX-XXXX (where 'X' can be [0-9, A-F])
See Also