Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Disable Worksheet Tab Menu

Found by recording a macro...

Private Sub Workbook_BeforeClose(Cancel As Boolean)
ActiveWindow.DisplayWorkbookTabs = True
End Sub

Private Sub Workbook_Open()
ActiveWindow.DisplayWorkbookTabs = False
End Sub



--
Message posted from http://www.ExcelForum.com

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 4,624
Default Disable Worksheet Tab Menu

I'd recommend using the Workbook_Activate and Workbook_Deactivate event
macros, instead of Open and BeforeClose. That way it only applies to
that workbook, even if there are multiple workbooks open in the XL
instance.



In article ,
kkknie wrote:

Found by recording a macro...

Private Sub Workbook_BeforeClose(Cancel As Boolean)
ActiveWindow.DisplayWorkbookTabs = True
End Sub

Private Sub Workbook_Open()
ActiveWindow.DisplayWorkbookTabs = False
End Sub

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Disable Worksheet Tab Menu

Thank you everyone for your assistance. I'm still having troubl
disabling the menu though. The following macro works great, but I nee
to be able to view the tabs. I need to disable the tab menu, but stil
view the tabs themselves, and I haven't been able to figure that on
out yet. Help?!?

Thank you!

Private Sub Workbook_BeforeClose(Cancel As Boolean)
ActiveWindow.DisplayWorkbookTabs = True
End Sub

Private Sub Workbook_Open()
ActiveWindow.DisplayWorkbookTabs = False
End Su

--
Message posted from http://www.ExcelForum.com

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,123
Default Disable Worksheet Tab Menu

He I was right then <g

Did you try my example ?

--
Regards Ron de Bruin
http://www.rondebruin.nl


"cjsmile2106 " wrote in message ...
Thank you everyone for your assistance. I'm still having trouble
disabling the menu though. The following macro works great, but I need
to be able to view the tabs. I need to disable the tab menu, but still
view the tabs themselves, and I haven't been able to figure that one
out yet. Help?!?

Thank you!

Private Sub Workbook_BeforeClose(Cancel As Boolean)
ActiveWindow.DisplayWorkbookTabs = True
End Sub

Private Sub Workbook_Open()
ActiveWindow.DisplayWorkbookTabs = False
End Sub


---
Message posted from http://www.ExcelForum.com/



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
VBA to disable "Delete...." on shortcut menu of worksheet tab? Mary Kathryn Excel Discussion (Misc queries) 3 March 3rd 06 05:54 PM
How disable menu command Armangelo Excel Discussion (Misc queries) 0 February 1st 06 10:00 AM
Disable menu selection andy Excel Discussion (Misc queries) 3 December 10th 04 10:46 PM
Disable Worksheet Tab Menu Ron de Bruin Excel Programming 1 June 1st 04 05:59 PM
Disable Menu Item OCI Excel Programming 0 May 19th 04 05:41 PM


All times are GMT +1. The time now is 11:22 PM.

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

About Us

"It's about Microsoft Excel"