ITCGetSerialNumber

Returns the serial number of the computer.

Syntax

HRESULT ITCGetSerialNumber(LPTSTR number, int buffSize)

Parameters

number
[out] Pointer to a null-terminated array of TCHARs that receives the serial number string. The caller must declare or allocate at least 12 TCHARs for this array.

buffSize
[in] Size of the 'number' array (the number of TCHARs in the string). Because a serial number is 11 characters long and null-terminated, the minimum allowable size for the array is 12 TCHARs.

Return Values

S_OK if successful.

E_FAIL if buffSize is not 12 or larger

Header and Library Files

Header File: ITC50.H

Library: ITC50.LIB

More Information

Computer Type and Serial Number Functions