5 error codes, 5 closehandle, 1 syntax – Lucent Technologies USS-720 User Manual

Page 66: 2 parameters, 3 return values, 4 notes, 3 i/o file functions

Advertising
background image

7-8

Lucent Technologies Inc.

USS-720

Preliminary User Guide, Rev. 2

USB Device Driver

February 1999

13

3 I/O File Functions

(continued)

3.4.5 Error Codes

ERROR_DEVICE_REMOVE—The device instance has been removed.

ERROR_DEVICE_STOP—The device instance has been stopped.

STATUS_INVALID_PARAMETER—Control Code is either invalid for this device instance or the device instance is
in a state that cannot process the Control Code.

See specific Control Code for other errors (see Section 4 of this document).

3.5 CloseHandle

The CloseHandle I/O function closes an instance of a device and returns TRUE if the function is successful and
FALSE if it fails. Details regarding the syntax, parameters, return values, and error codes are listed below.

3.5.1 Syntax

BOOL
CloseHandle(

HANDLE hDev
);

3.5.2 Parameters

Input:
hDev—Handle returned from a successful CreateFile.

Output:
None.

3.5.3 Return Values

If the function succeeds, the return value is TRUE (1).

If the function fails, the return value is FALSE (0). To get extended error information, call GetLastError.

3.5.4 Notes

See the

Win32 SDK documentation for complete definitions.

3.5.5 Error Codes

See

WIN32 SDK documentation for possible errors.

Advertising