|
-
Mar 9th, 2004, 07:01 AM
#1
Thread Starter
Hyperactive Member
Hiding Excel
Can someone tell me how to hide the worksheet menu bar.
I've tried this code:
VB Code:
application.commandbars("Worksheet menu Bars").Visible = False
but , it doesn't work. Can someone help me please?!!?
Thanks in advance,
Greyskull
-
Mar 9th, 2004, 09:53 AM
#2
Addicted Member
Something like this (untested) at your own risk (grin) :-
'---------------------------------------
Sub untested()
For Each b In Application.CommandBars
b.Visible = False
Next
End Sub
'---------------------------------------
Regards
BrianB
-------------------------------
-
Mar 10th, 2004, 07:53 AM
#3
Thread Starter
Hyperactive Member
I've already done this by having this code
VB Code:
Sub OK()
For Each onebar In Application.CommandBars
onebar.Visible = False
Next
End Sub
But it still doesn't remove it.
Thanx anyways
-
Mar 10th, 2004, 10:28 PM
#4
Lively Member
Here is what you are looking for:
Same question asked just last week - try searching the archives before you post.
[Highlight=VB]
Dim Bar As CommandBar
For Each Bar In Application.CommandBars
Bar.Enabled = False
Next
[\vbcode]
-----
#VBA, VB 6 Professional Edition, Office XP Developper. Excel 97, Excel 2000, Excel XP
I miss my VIC 20.
Never should have upgraded to my commodore 64. ...
-
Mar 11th, 2004, 05:24 AM
#5
Junior Member
try reading the post before condeming it fiddler.
The code you've posted doesn't actually work - it seems to be office XP that causes it problems as that code does work with excel prior to that.
I'm runing office xp with windows xp pro and that code hasn't worked for me since I upgraded.
- update -
my bad, just added sp3 for office xp and the code works?
Last edited by Shattered; Mar 11th, 2004 at 05:28 AM.
"much to learn you still have"
-
Mar 11th, 2004, 12:16 PM
#6
Lively Member
Works for me in Excel 97, and Excel XP (using sp-2)
It's about using the .enabled property and not the .visible property.
I was having a long day yesterday - didn't mean to be spitefull. And I did post the same thing just last week.
-----
#VBA, VB 6 Professional Edition, Office XP Developper. Excel 97, Excel 2000, Excel XP
I miss my VIC 20.
Never should have upgraded to my commodore 64. ...
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|