Previous PageNext Page

7.13 Drive Object

The Drive object provides access to the properties of a particular disk drive or network share.
 

Properties

AvailableSpace
 
The amount of space available to a user. This property is not currently supported on UNIX.
 
DriveLetter
 
The drive letter of a physical drive or network share. This property is not currently supported on UNIX.
 
DriveType
 
The type of a drive. This property is not currently supported on UNIX.
 
FileSystem
 
The type of file system in use on the drive. This property is not currently supported on UNIX.
 
FreeSpace
 
The amount of free space available to a user on a specified drive or network share. This property is currently not supported on UNIX.
 
IsReady
 
Boolean value indicating the status of a drive.
 
Path
 
The file system path to the drive.
 
RootFolder
 
A Folder object representing the root folder of a drive.
 
SerialNumber
 
The decimal serial number used to uniquely identify a disk volume. This property is not currently supported on UNIX.
 
ShareName
 
The network share name for the drive. This property is not currently supported on UNIX.
 
TotalSize
 
The total size, in bytes, of a drive or network share. This property is not currently supported on UNIX.
 
VolumeName
 
The volume name of a drive or network share. This property is not currently supported on UNIX.
 

Remarks

The following code illustrates the use of the Drive object to access drive properties:
 

function ShowUsedSpace(drvPath)

{

var fs, d, s;

fs = new ActiveXObject("Scripting.FileSystemObject");

d = fs.GetDrive(fs.GetDriveName(drvPath));

s = "Space used on drive " + drvPath + " - " ;

s += d.RootFolder.Size/1024 + " Kbytes";

Response.Write(s);

}


Copyright © 2000 Chili!Soft

Previous PageTop Of PageNext Page