[x]
Posted via EE Mobile

Search, ask, and monitor your questions on the go with EE Mobile. Visit Experts Exchange from your mobile device and never be out of touch again.

09/09/2009 at 12:59AM PDT, ID: 24717373 | Points: 500
[x]
Attachment Details

Open file as read only depending on user ID

Asked by GordonMasson in Microsoft Excel Spreadsheet Software

Hi
I have an excel spread sheet that is used by several "primary users" who can modify the sheet but I also want to allow other users to view the file as read only but I want to do this automatically.
On a page of the workbook I have all the ID's of the primary users so I can write a bit of code that will detect if its one of those users thats opened the file.
Not exactly sure where this code would go & is there a File_Open Sub or something that is executed before anything else?

What I want to do is this:

1. If it's not one of the primary users then open a read only version of the file.
I assume this would mean as many non primary users as you like could all open read only versions of the file and there would be no limit to the number of read only versions open at any one time?

2. If the sheet is already open and being used by one of the primary users then I want to flag up a message box saying "Primary User Joe Blogs currently has the file open. Do you want to open a read only copy?"

Thanks for your help
[+][-]09/09/09 04:41 AM, ID: 25290091

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]09/10/09 05:29 AM, ID: 25299473

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
 
Loading Advertisement...
20091111-EE-VQP-91 - Hierarchy / EE_QW_3_20080625