Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 43
Default Eliminating Toolbars,Sheet Tabs,Scroll Bars. etc.

I am having trouble writing a macro to disable all toolbars. I also want to
turnoff the column and row headings as well as the sheet tabs and scroll bars.
And I would like to restore all of these when the program closes. I only want
the toolbars to be disabled during the program and I want the toolbars there
if I open another Excel file. Is this possible to do with a macro?

--
Message posted via OfficeKB.com
http://www.officekb.com/Uwe/Forums.a...mming/200602/1
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,123
Default Eliminating Toolbars,Sheet Tabs,Scroll Bars. etc.

Hi

Start here
http://www.rondebruin.com/menuid.htm

the column and row headings as well as the sheet tabs and scroll bars

record a macro when you do this manual

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


"mtm4300 via OfficeKB.com" <u18572@uwe wrote in message news:5bf99a0f23364@uwe...
I am having trouble writing a macro to disable all toolbars. I also want to
turnoff the column and row headings as well as the sheet tabs and scroll bars.
And I would like to restore all of these when the program closes. I only want
the toolbars to be disabled during the program and I want the toolbars there
if I open another Excel file. Is this possible to do with a macro?

--
Message posted via OfficeKB.com
http://www.officekb.com/Uwe/Forums.a...mming/200602/1



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,272
Default Eliminating Toolbars,Sheet Tabs,Scroll Bars. etc.

Option Explicit

Private mFormulaBar
Private mStatusbar

Private Sub Workbook_BeforeClose(Cancel As Boolean)
Dim oCB As CommandBar
For Each oCB In Application.CommandBars
oCB.Enabled = True
Next oCB

With ActiveWindow
.DisplayHeadings = True
.DisplayHorizontalScrollBar = True
.DisplayVerticalScrollBar = True
.DisplayWorkbookTabs = True
End With

Application.DisplayFormulaBar = mFormulaBar
Application.StatusBar = mStatusBar

End Sub

Private Sub Workbook_Open()
Dim oCB As CommandBar
For Each oCB In Application.CommandBars
oCB.Enabled = False
Next oCB

With ActiveWindow
.DisplayHeadings = False
.DisplayHorizontalScrollBar = False
.DisplayVerticalScrollBar = False
.DisplayWorkbookTabs = False
End With

mFormulaBar = Application.DisplayFormulaBar
Application.DisplayFormulaBar = False
mStatusBar = Application.StatusBar
Application.StatusBar = False
End Sub

'This is workbook event code.
'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



--
HTH

Bob Phillips

(remove nothere from email address if mailing direct)

"mtm4300 via OfficeKB.com" <u18572@uwe wrote in message
news:5bf99a0f23364@uwe...
I am having trouble writing a macro to disable all toolbars. I also want

to
turnoff the column and row headings as well as the sheet tabs and scroll

bars.
And I would like to restore all of these when the program closes. I only

want
the toolbars to be disabled during the program and I want the toolbars

there
if I open another Excel file. Is this possible to do with a macro?

--
Message posted via OfficeKB.com
http://www.officekb.com/Uwe/Forums.a...mming/200602/1



  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 43
Default Eliminating Toolbars,Sheet Tabs,Scroll Bars. etc.

Thank you.

Bob Phillips wrote:
Option Explicit

Private mFormulaBar
Private mStatusbar

Private Sub Workbook_BeforeClose(Cancel As Boolean)
Dim oCB As CommandBar
For Each oCB In Application.CommandBars
oCB.Enabled = True
Next oCB

With ActiveWindow
.DisplayHeadings = True
.DisplayHorizontalScrollBar = True
.DisplayVerticalScrollBar = True
.DisplayWorkbookTabs = True
End With

Application.DisplayFormulaBar = mFormulaBar
Application.StatusBar = mStatusBar

End Sub

Private Sub Workbook_Open()
Dim oCB As CommandBar
For Each oCB In Application.CommandBars
oCB.Enabled = False
Next oCB

With ActiveWindow
.DisplayHeadings = False
.DisplayHorizontalScrollBar = False
.DisplayVerticalScrollBar = False
.DisplayWorkbookTabs = False
End With

mFormulaBar = Application.DisplayFormulaBar
Application.DisplayFormulaBar = False
mStatusBar = Application.StatusBar
Application.StatusBar = False
End Sub

'This is workbook event code.
'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

I am having trouble writing a macro to disable all toolbars. I also want to
turnoff the column and row headings as well as the sheet tabs and scroll bars.
And I would like to restore all of these when the program closes. I only want
the toolbars to be disabled during the program and I want the toolbars there
if I open another Excel file. Is this possible to do with a macro?


--
Message posted via OfficeKB.com
http://www.officekb.com/Uwe/Forums.a...mming/200602/1
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
How do I show scroll bars and tabs in Excel 2007 geoffa1 Setting up and Configuration of Excel 2 August 2nd 07 07:12 PM
Lost scroll bars and sheet tabs??? TinaMo Excel Discussion (Misc queries) 2 June 22nd 07 04:25 AM
Scroll bars without control tabs CJ Excel Worksheet Functions 3 August 23rd 06 12:55 AM
Sheet tabs and scroll bars Tom Russell Setting up and Configuration of Excel 12 February 24th 06 01:16 AM
Excel opens saved workbook without tabs or scroll bars showing? Dave W Franklin Excel Worksheet Functions 1 May 11th 05 11:11 PM


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