Pinaceous
Well-known Member
- Joined
- Jun 11, 2014
- Messages
- 1,113
- Office Version
- 365
- Platform
- Windows
Hi All,
I'm working with the drive path within a sub:
I'm interested in a code that can indicate the name of the file as seen above referenced within the workbook itself.
For example:
This is the idea that I'm exploring:
where the drive path references the name of the file as a location in the workbook.
Please let me know, if this is possible.
Thank you,
pinaceous
I'm working with the drive path within a sub:
VBA Code:
FSO.MoveFile Source:="C:\Users\Desktop\Test(2020).xlsm", Destination:=sMain & "\Test(2020).xlsm" ' copy and delete from source
I'm interested in a code that can indicate the name of the file as seen above referenced within the workbook itself.
For example:
Code:
FSO.MoveFile Source:="C:\Users\Desktop\ &ThisWorkBook.Sheets(1)Range("A1").Value", Destination:=sMain & "\&ThisWorkBook.Sheets(1)Range("A1").Value" ' copy and delete from source
This is the idea that I'm exploring:
&ThisWorkBook.Sheets(1)Range("A1").Value
where the drive path references the name of the file as a location in the workbook.
Please let me know, if this is possible.
Thank you,
pinaceous