Is there a VBA method for extracting the original server path of an Excel file when working from a local temp file

  Kiến thức lập trình

Im trying to SaveAs a file that is stored on a server in a different file format. The sub folders that the file is stored in on the server wont be consistent so I cant simply write the path in as a string I need to be able to extract it dynamically.

The true path of the file is:

smb://xxx.xxx.x.xx/Jobs24/Graphic Group/164626/_data/FileName.xlsx

But when I use ActiveWorkbook.FullName I get:

/Users/oliver/Library/Containers/com.microsoft.Excel/Data/Documents/FileName.xlsx

Is there a method that will pull the true path? Since ActiveWorkbook.Save works as intended I assume that information is in there somewhere.

I’ve tried using fso.get and Workbook.FullName but they only pull the local temp path. All the documentation I find is for finding the local file path when I need the server file path. Or the documentation is about finding out the server path manually and then writing it as a string. I cant do that since the exact path wont always be the same.

New contributor

Oliver Prevost is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.

Theme wordpress giá rẻ Theme wordpress giá rẻ Thiết kế website

LEAVE A COMMENT