Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 31
Default Hide Custom Command Bar if Workbook opened Read-Only

When I open my workbook read-only, the macro listed below runs. How
do I also have my custom command bar hide as well?

Sub ShowAffOnly()
Dim wsSheet As Worksheet
For Each wsSheet In Worksheets
If wsSheet.Name < "Affiliation" Then wsSheet.Visible = xlVeryHidden
Next wsSheet
End Sub
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 10,593
Default Hide Custom Command Bar if Workbook opened Read-Only

Application.Commandbars("MyCustom").Visible = False

--
HTH

Bob

(there's no email, no snail mail, but somewhere should be gmail in my addy)

wrote in message
...
When I open my workbook read-only, the macro listed below runs. How
do I also have my custom command bar hide as well?

Sub ShowAffOnly()
Dim wsSheet As Worksheet
For Each wsSheet In Worksheets
If wsSheet.Name < "Affiliation" Then wsSheet.Visible = xlVeryHidden
Next wsSheet
End Sub



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 31
Default Hide Custom Command Bar if Workbook opened Read-Only

On Apr 28, 3:59*am, "Bob Phillips" wrote:
Application.Commandbars("MyCustom").Visible = False

--
HTH

Bob

(there's no email, no snail mail, but somewhere should be gmail in my addy)

wrote in message

...



When I open my workbookread-only, the macro listed below runs. * How
do I also have my custom command bar hide as well?


Sub ShowAffOnly()
Dim wsSheet As Worksheet
For Each wsSheet In Worksheets
IfwsSheet.Name < "Affiliation" Then wsSheet.Visible = xlVeryHidden
Next wsSheet
End Sub- Hide quoted text -


- Show quoted text -


Thank you so much. I wish I would learn to quit making it harder than
it is.
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 Workbook Read Only and hide select worksheets imelda1ab Excel Programming 10 March 27th 08 02:33 PM
stop excel file opened as read only if already opened by another u bobm Excel Programming 3 August 5th 05 04:11 PM
Rules that act on messages after they are opened & read? Perotin Excel Discussion (Misc queries) 1 December 5th 04 12:31 AM
Is Workbook read-only because of file permission or because file is already opened? balexis Excel Programming 0 September 29th 04 02:29 PM
How to read sheet of currently opened workbook Jedi[_2_] Excel Programming 1 September 11th 03 11:00 AM


All times are GMT +1. The time now is 02:23 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"