I am trying to display and check if a user is using the correct version of a file. I keep getting an error on "Workbooks.Filename" and can't figure out how to modify code. Thanks.
Please Login or Register to view this content.
I am trying to display and check if a user is using the correct version of a file. I keep getting an error on "Workbooks.Filename" and can't figure out how to modify code. Thanks.
Please Login or Register to view this content.
Last edited by maacmaac; 11-26-2010 at 12:12 AM.
Where would you place a code like this?
Hi maacmaac
This works for meJohnPlease Login or Register to view this content.
John
If you have issues with Code I've provided, I appreciate your feedback.
In the event Code provided resolves your issue, please mark your Thread as SOLVED.
If you're satisfied by any members response to your issue please use the star icon at the lower left of their post.
John,
Suggestion almost worked. If the workbook name is "Book2", the ActiveWorkbook.Name = "Book2". The ActiveWorkbook.Name is only recognizing the name of the workbook not the full path name. Is there a way to modify so it also reads the full path name?
Dave,
I am trying to prevent prying eyes from copying my file and placing a copy on another server for their own personal use. As an example, say my file is located on "O:/Department ABC/MetricsApplication.xls". I'm trying to prevent users from other departments copying my file and using it for their own use. So if someone were to copy my file to "O:/Department XYZ/MetricsApplication.xls", I want to prevent the file from opening. In a nutshell, if the file being opened is not located on "O:/Department ABC/MetricsApplication.xls", then don't open the file.
Just figured it out...use "ActiveWorkbook.FullName" instead of "ActiveWorkbook.Name"
Please Login or Register to view this content.
Yes...realized that when I read your last post...need to pick up FULL path and filename. Good detective work.
John
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks