Important Notice
The pages on this site contain documentation for very old MS-DOS software,
purely for historical purposes.
If you're looking for up-to-date documentation, particularly for programming,
you should not rely on the information found here, as it will be woefully
out of date.
DosDevIOCtl2 (1.2)
◄Up► ◄Next► ◄Previous►
────────────────────────────────────────────────────────────────────────────
#define INCL_DOSDEVICES
USHORT DosDevIOCtl2(pvData, cbData, pvParmList, cbParmList, usFunct,
usCat, hDev);
PVOID pvData; /* pointer to buffer for data */
USHORT cbData; /* length of data buffer */
PVOID pvParmList; /* pointer to list of parameters */
USHORT cbParmList; /* length of parameter list */
USHORT usFunct; /* function code */
USHORT usCat; /* device category */
HFILE hDev; /* device handle */
The DosDevIOCtl2 function performs control functions on the device specified
by the file or device handle.
Parameter Description
────────────────────────────────────────────────────────────────────────────
pvData Points to a data buffer.
cbData Specifies the length (in bytes) of the data buffer.
pvParmList Points to an argument list for a specified command.
cbParmList Specifies the length (in bytes) of the argument list for a
specified command.
usFunct Specifies a function code for a specified device. This parameter
can be any value from 0 through 255.
usCat Specifies a device category. This parameter can be any value
from 0 through 255.
hDev Identifies the device. This handle must have been created
previously by using the DosOpen function.
Return Value
The return value is zero if the function is successful. Otherwise, it is an
error value, which may be one of the following:
ERROR_INVALID_CATEGORY
ERROR_INVALID_DRIVE
ERROR_INVALID_FUNCTION
ERROR_INVALID_HANDLE
ERROR_INVALID_PARAMETER
Comments
This function provides a way for a program to implement a customized IOCtl
function.
If the pvData parameter is zero, this parameter is not defined for the
IOCtl function being specified, and the value passed in the cbData parameter
is ignored.
If the pvParmList parameter is zero, this parameter is not defined for the
IOCtl function being specified, and the value passed in the cbParmList
parameter is ignored.
Whenever the pvData or pvParmList parameter is a value other than zero, the
associated length parameter cannot be zero. The length parameters are not
passed to device drivers that do not support them.
See Also
DosDevIOCtl
♦