CloseDev

int CloseDev (int Device);

Purpose

Closes a device.

Parameters

Input
Name Type Description
Device integer The device to close.

Return Value

Name Type Description
result integer Result of the close device operation.

Return Codes

Code Description
-1 Error—cannot find device.
0 Success.

Using This Function

Takes a device offline. CloseDev first calls ibloc and then calls ibonl with a value of zero. Device is the device descriptor you obtain when you open the device with OpenDev. If CloseDev cannot find the device descriptor in its table, it returns a -1. You should use CloseDev only in conjunction with OpenDev. Never call CloseDev with a device descriptor you obtain by calling ibfind.