The Move method moves a file from one location to another. This method takes a single parameter, destination, which represents the location to which the file is to be moved.
<html> <body> <script language="JScript"> <!-- function move() { var myObject, f; myObject = new ActiveXObject("Scripting.FileSystemObject"); f = myObject.GetFile("c:\test.txt"); f.Move("D:\"); } //--> </script> Move the file test.txt <form name="myForm"> <input type="Button" vvalue="Move File" onClick='move()'> </form> </body> </html>