By David Wiseman (Administrator)Created 21 Nov 2006
My Rating:
Vote
Rating:
Not Rated
Views:5426
Downloads:119

Move a file

Language:  VBScript

Compatibility

Windows XP Yes Windows 2003 Yes
Windows 2000 Yes Windows NT Unknown
Vista Unknown Windows 2008 Unknown
Description

Move a file to a different folder. (Can also be used to rename a file)

Code

Line Numbers: On  Off      Plain Text
strSource = "c:\myfile.txt"
strDestination = "C:\newfolder\myfile.txt"

set objFSO = createobject("Scripting.FileSystemObject")
objFSO.MoveFile strSource,strDestination

 


Got a useful script? Click here to upload!


 

  Post Comment
Order By:  
User Comments
      
Be the first to post a comment!