Prompt a user to rename a file thats on your desktop.
Prompt a user to rename a file thats on your desktop.
Rate Prompt a user to rename a file thats on your desktop.
(1(1 Vote))
On Error GoTo Exception_Handler:
Dim PreviousFileName, NewFileName As String
PreviousFileName = "C:\Windows\Desktop\File1.txt"
NewFileName = InputBox("What do you wish to rename " & PreviousFileName & "?", "Rename File")
NewFileName = "C:\Windows\Desktop " & "\" & NewFileName & ".txt"
Name PreviousFileName As NewFileName
Exit Sub
Exception_Handler:
MsgBox Err.Description, vbCritical, "Error"
Prompt a user to rename a file thats on your desktop. Comments
No comments yet — be the first to post one!
Post a Comment