View Single Post
  #5   Report Post  
Bob Phillips
 
Posts: n/a
Default

Hi Ditchy,

Workbook event code goes in the THisWorkbook code module. To input this
code, right click on the Excel icon on the worksheet '(or next to the File
menu if you maximise your workbooks),
select View Code from the menu, and paste the code

The gloabl variable should be created in a normal code module, circa

Public fAlwaysShown As Boolean

and then, in you button macro, something like

'your code to get a password
If password_correct Then ' sub with your logiv
fAlwaysShown = True
Application.CommandBars("Worksheet Menu Bar").Enabled = True
End IF


--

HTH

RP
(remove nothere from the email address if mailing direct)


"ditchy" wrote in message
oups.com...
Hi BoB
cold you explain to me how I go about adding the workbook_activate
event, and create a global
variable fAlwaysShown and set that to true when the password is
entered..
I am not right up with macros yet, only what I have picked up from this
group.
Thanks for your help
Regards, Ditchy