L
Little Pete
I use a simple .js script to shuffle files on my computer to which I'd
like to add alert and confirmation boxes. Unfortunately I haven't been
able to figure out what object I need to create that has these methods.
What is missing from this .js script:
var source = "source.txt";
var destination = "destination.txt";
if (confirm("Make Changes?"))
{
var fso = new ActiveXObject("Scripting.FileSystemObject");
fso.CopyFile(source, destination, true);
alert("Changes made.");
}
else
{
alert("No changes made.");
}
Thanks, Pete.
like to add alert and confirmation boxes. Unfortunately I haven't been
able to figure out what object I need to create that has these methods.
What is missing from this .js script:
var source = "source.txt";
var destination = "destination.txt";
if (confirm("Make Changes?"))
{
var fso = new ActiveXObject("Scripting.FileSystemObject");
fso.CopyFile(source, destination, true);
alert("Changes made.");
}
else
{
alert("No changes made.");
}
Thanks, Pete.