Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 454
Default Worksheet Open Event Q

I have some code that will only open a Workbook if a User is listed
within a Named Range. The user is dependent on selecting a dropdown
within the file itself, thus "before the workbook is opened" this
value will be blank, to counter this I have a formula in the Named
Range that says if The User cell is blank, return the applications
username, thus it gets past the situation where its the incorrect user
temporarily, or so I thought, the Workbook has to Open in order to
refresh this formula

Any ideas of how I could get around this, in essense anyone should be
able to open the file, but when the User is selected, the rules kick
in

Thanks

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,058
Default Worksheet Open Event Q

To by-pass the "RULE", set the security level of Excel to enable the by-pass
of all macro functions.
--
Gary's Student
gsnu200707


"Sean" wrote:

I have some code that will only open a Workbook if a User is listed
within a Named Range. The user is dependent on selecting a dropdown
within the file itself, thus "before the workbook is opened" this
value will be blank, to counter this I have a formula in the Named
Range that says if The User cell is blank, return the applications
username, thus it gets past the situation where its the incorrect user
temporarily, or so I thought, the Workbook has to Open in order to
refresh this formula

Any ideas of how I could get around this, in essense anyone should be
able to open the file, but when the User is selected, the rules kick
in

Thanks


  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 116
Default Worksheet Open Event Q

Hide the sheets and open it to a userform. Put code in the userform to check
the name and if OK unhide the sheets and close the form, otherwise msgbox,
You are not unauthorized to open this document. Put an close event that
rehides the sheets. Just a thought.

Regards,

Alan


"Sean" wrote in message
oups.com...
I have some code that will only open a Workbook if a User is listed
within a Named Range. The user is dependent on selecting a dropdown
within the file itself, thus "before the workbook is opened" this
value will be blank, to counter this I have a formula in the Named
Range that says if The User cell is blank, return the applications
username, thus it gets past the situation where its the incorrect user
temporarily, or so I thought, the Workbook has to Open in order to
refresh this formula

Any ideas of how I could get around this, in essense anyone should be
able to open the file, but when the User is selected, the rules kick
in

Thanks



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Open Event jlclyde Excel Discussion (Misc queries) 5 September 17th 08 09:18 PM
Need help re VBA for Worksheet Open Event LucyRB Excel Programming 5 January 12th 06 07:01 PM
user form-on open event? keydown event? FSt1[_3_] Excel Programming 2 August 5th 04 02:26 PM
Event Procedures: Event on Worksheet to fire Event on another Worksheet Kathryn Excel Programming 2 April 7th 04 07:35 PM


All times are GMT +1. The time now is 09:40 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"