[Toc][Index]

DosQHandType


Bindings:  C, MASM 

This call determines whether a handle references a file or a device. 
 DosQHandType     (FileHandle, HandType, FlagWord) 
 
 FileHandle (HFILE) - input 
    File handle. 
 HandType (PUSHORT) - output 
    Address of the value indicating the handle type. HandType is composed 
    of two bytes: 
    Bit       Description 
    15        Network bit: 
              0 = The handle refers to a local file, device, or pipe. 
              1 = Means that the handle refers to a remote file, device, 
              or pipe. 
    14-8      Reserved. 
    7-0       HandleClass describes the handle class.  It may take on the 
              following values in the low byte of HandleType: 
       Value     Definition 
       0         Handle is for a disk file 
       1         Handle is for a character device 
       2         Handle is for a pipe. 
                 Values greater than 2 are reserved. 
 FlagWord (PUSHORT) - output 
    Address of the device driver's attribute word if HandleType indicates 
    a local character device. 
 rc (USHORT) - return 
    Return code descriptions are: 
    0         NO_ERROR 
    6         ERROR_INVALID_HANDLE 
 
 Remarks 
 This function allows programs that are interactive or file-oriented to 
 determine the source of their input.  For example, CMD.EXE suppresses 
 writing prompts if the input is from a disk file. 

Created using Inf-PHP v.2 (c) 2003 Yuri Prokushev
Created using Inf-HTML v.0.9b (c) 1995 Peter Childs