Share this page

# chdrive

Example: chdrive | File Manipulation Functions

Switches to another drive on a Windows operating system.

    int  chdrive( int drive);

drive | The name of a drive.

chdrive changes the current working drive to be drive, an integer representing the new drive. (1 = A, 2 = B, etc.)

## Return Values

The chdrive function returns zero on success and (-1) for failure.

Tips to improve your search results... VuGen Function Reference Version 25.1-25.3 Function Reference 25.1-25.3 All View Local Help Center View Online Help Center Version: