3.12 File Input and Output Functions

File I/O functions create, open, read from, write to, and close files. Following are the file I/O functions:

Function Description

GetDriveType Determines whether a disk drive is removable, fixed, or remote.
GetSystemDirectory Retrieves the path of the Windows system subdirectory.
GetTempDrive Returns the letter of the optimal drive for temporary file storage.
GetTempFileName Creates a temporary filename.
GetWindowsDirectory Retrieves the path of the Windows directory.
_hmemcpy Copies bytes.
_hread Reads from a file.
_hwrite Writes to a file.
_lclose Closes a file.
_lcreat Creates a new file or opens and truncates an existing file.
_llseek Positions the pointer to a file.
_lopen Opens an existing file.
_lread Reads data from a file.
_lwrite Writes data to a file.
OpenFile Creates, opens, reopens, or deletes the specified file.
SetHandleCount Changes the number of file handles available to a task.