I am trying to rename a file and was using the below code but it does not seem to work. Can someone please tell me why? What is the correct way to rename a file from VBScrip
Yes you can do that. Here I am renaming a .exe file to .txt file
rename a file
Dim objFso Set objFso= CreateObject("Scripting.FileSystemObject") objFso.MoveFile "D:\testvbs\autorun.exe", "D:\testvbs\autorun.txt"