Hi,
Can anyone help me to provide VBA code to display UNC path \\servername\sharename\path\filename
I only know the code for normal path msgbox thisworkbook.fullname
Regards,
Farid
Hi,
Can anyone help me to provide VBA code to display UNC path \\servername\sharename\path\filename
I only know the code for normal path msgbox thisworkbook.fullname
Regards,
Farid
That gives me the full path, hope it helps.Please Login or Register to view this content.
Hi Faridwahidi,
As long as the workbook has been saved, this should do the trick:
HTHPlease Login or Register to view this content.
Robert
____________________________________________
Please ensure you mark your thread as Solved once it is. Click here to see how
If this post helps, please don't forget to say thanks by clicking the star icon in the bottom left-hand corner of my post
Hi,
This is not UNC path. \\servername\sharename\path\filename
That path can be easily obtained by using these methods
1. Formula =SUBSTITUTE(LEFT(CELL("filename",A1),FIND("]",CELL("filename",A1))-1),"[","")
2. or just Add Document Location in quick Access Toolbar.
Hi Trebor76,
That is what I want. thanks a lot
Regards,
Farid
Certainly when I run it, it does give all that information. You must of course (as Trebor76 said above) run it on a saved workbook however.
If you want to exclude file name jusr use:
instead of .fullnamePlease Login or Register to view this content.
Hi,
my 1st comment refer to TKCBZW reply
I know this is marked as solved, but I just stumbled across this link which may provide a little more colour:
http://support.microsoft.com/kb/160529
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks