ASP DriveExists Method
Complete FileSystemObject object reference manual
The DriveExists method returns a Boolean value indicating whether the specified drive exists. It returns True if the drive exists, otherwise False.
Syntax
FileSystemObject.DriveExists(drive)
| Parameters | Description |
|---|---|
| drive | Required. The drive letter or a full path specification. |
Example
<%
dim fs
set fs=Server.CreateObject("Scripting.FileSystemObject")
if fs.DriveExists("c:")=true then
response.write("Drive c: exists!")
else
response.write("Drive c: does not exist.")
end If
set fs=nothing
%>
Complete FileSystemObject object reference manual