Articles in the Javascript Category
Javascript »
Get Client System’s Drive List : JavaScript
In many cases if you want to know the drive list of client system using some client scripting then the best one is JavaScript, actually Activex Scripting.FileSystemObject provides the functionality.
<HTML>
<HEAD>
<SCRIPT language=JavaScript>
//Following function returns the drive list from client system
function getClientDrives() {
var objfs, s, n, e, x;
objfs = new ActiveXObject(“Scripting.FileSystemObject”);
e = new Enumerator(objfs.Drives);
s = “”;
do {
x = e.item();
s = s + x.DriveLetter;
s += “: “;
if (x.DriveType == 3) n = x.ShareName;
else if (x.IsReady) n = x.VolumeName;
else n = “<font color=red>[Other Drive-not …
