- Joined
 - Mar 9, 2017
 
- Messages
 - 2
 
- Reaction score
 - 2
 
I'm returning to VBA after years, and I'm trying to rename files in VBA (working inside Word)
The command:
My.Computer.FileSystem.RenameFile strOld, strNew
gets the following error: Compile error: Variable Not defined and highlights "My"
My.computer.FileSystem.RenameFile locFolder
I'm assuming that I'm missing an include or import or something, but I haven't done this in so long I'm not sure how.
Please help!
Thanks, Michael T.
				
			The command:
My.Computer.FileSystem.RenameFile strOld, strNew
gets the following error: Compile error: Variable Not defined and highlights "My"
My.computer.FileSystem.RenameFile locFolder
I'm assuming that I'm missing an include or import or something, but I haven't done this in so long I'm not sure how.
Please help!
Thanks, Michael T.
	
. Thanks for reporting back with the solution!