Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
Bob Bob is offline
external usenet poster
 
Posts: 972
Default Disabling row and column headers option

Is there a way in VBA to disable the "Row and column headers" option within
the Tools | Options... | View tab menu so that a user cannot check (or
uncheck) the checkbox? I would like to do this without having to create a
custom toolbar or menu.

Thanks in advance for any guidance.

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 35,218
Default Disabling row and column headers option

I don't think you can change any of those built-in dialogs.

You can disable them, but you can't change them.

Bob wrote:

Is there a way in VBA to disable the "Row and column headers" option within
the Tools | Options... | View tab menu so that a user cannot check (or
uncheck) the checkbox? I would like to do this without having to create a
custom toolbar or menu.

Thanks in advance for any guidance.


--

Dave Peterson
  #3   Report Post  
Posted to microsoft.public.excel.programming
Bob Bob is offline
external usenet poster
 
Posts: 972
Default Disabling row and column headers option

Dave,

What I want to do is click on the "Row and column headers" checkbox so that
the row and column headers are not displayed. Then I want to prevent users
from re-displaying the row and column headers (i.e., unchecking the checkbox).

Can you tell me how to disable the "Row and column headers" checkbox in VBA?

Thanks,
Bob


"Dave Peterson" wrote:

I don't think you can change any of those built-in dialogs.

You can disable them, but you can't change them.

Bob wrote:

Is there a way in VBA to disable the "Row and column headers" option within
the Tools | Options... | View tab menu so that a user cannot check (or
uncheck) the checkbox? I would like to do this without having to create a
custom toolbar or menu.

Thanks in advance for any guidance.


--

Dave Peterson

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 35,218
Default Disabling row and column headers option

Nope. I can't.

You don't have that kind of granular control over the dialogs in excel.

In my USA version of Excel, I could use a line like this:

With Application.CommandBars("worksheet menu bar").Controls("Tools")
'.enabled or .visible????
.Controls("Options...").Enabled = False
End With

to try to prevent users from clicking on Tools|Options...

But if they reset the toolbar or disabled macros, then it would not work very
well!

Bob wrote:

Dave,

What I want to do is click on the "Row and column headers" checkbox so that
the row and column headers are not displayed. Then I want to prevent users
from re-displaying the row and column headers (i.e., unchecking the checkbox).

Can you tell me how to disable the "Row and column headers" checkbox in VBA?

Thanks,
Bob

"Dave Peterson" wrote:

I don't think you can change any of those built-in dialogs.

You can disable them, but you can't change them.

Bob wrote:

Is there a way in VBA to disable the "Row and column headers" option within
the Tools | Options... | View tab menu so that a user cannot check (or
uncheck) the checkbox? I would like to do this without having to create a
custom toolbar or menu.

Thanks in advance for any guidance.


--

Dave Peterson


--

Dave Peterson
  #5   Report Post  
Posted to microsoft.public.excel.programming
Bob Bob is offline
external usenet poster
 
Posts: 972
Default Disabling row and column headers option

Dave,
As a second option, I guess I could do something like:

Private Sub Worksheet_Activate()
ActiveWindow.DisplayHeadings = False
End Sub

Thanks again for all your help and advice.
Bob


"Dave Peterson" wrote:

Nope. I can't.

You don't have that kind of granular control over the dialogs in excel.

In my USA version of Excel, I could use a line like this:

With Application.CommandBars("worksheet menu bar").Controls("Tools")
'.enabled or .visible????
.Controls("Options...").Enabled = False
End With

to try to prevent users from clicking on Tools|Options...

But if they reset the toolbar or disabled macros, then it would not work very
well!

Bob wrote:

Dave,

What I want to do is click on the "Row and column headers" checkbox so that
the row and column headers are not displayed. Then I want to prevent users
from re-displaying the row and column headers (i.e., unchecking the checkbox).

Can you tell me how to disable the "Row and column headers" checkbox in VBA?

Thanks,
Bob

"Dave Peterson" wrote:

I don't think you can change any of those built-in dialogs.

You can disable them, but you can't change them.

Bob wrote:

Is there a way in VBA to disable the "Row and column headers" option within
the Tools | Options... | View tab menu so that a user cannot check (or
uncheck) the checkbox? I would like to do this without having to create a
custom toolbar or menu.

Thanks in advance for any guidance.

--

Dave Peterson


--

Dave Peterson



  #6   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 35,218
Default Disabling row and column headers option

You could use that, but the user could disable macros or events or just change
the option.



Bob wrote:

Dave,
As a second option, I guess I could do something like:

Private Sub Worksheet_Activate()
ActiveWindow.DisplayHeadings = False
End Sub

Thanks again for all your help and advice.
Bob

"Dave Peterson" wrote:

Nope. I can't.

You don't have that kind of granular control over the dialogs in excel.

In my USA version of Excel, I could use a line like this:

With Application.CommandBars("worksheet menu bar").Controls("Tools")
'.enabled or .visible????
.Controls("Options...").Enabled = False
End With

to try to prevent users from clicking on Tools|Options...

But if they reset the toolbar or disabled macros, then it would not work very
well!

Bob wrote:

Dave,

What I want to do is click on the "Row and column headers" checkbox so that
the row and column headers are not displayed. Then I want to prevent users
from re-displaying the row and column headers (i.e., unchecking the checkbox).

Can you tell me how to disable the "Row and column headers" checkbox in VBA?

Thanks,
Bob

"Dave Peterson" wrote:

I don't think you can change any of those built-in dialogs.

You can disable them, but you can't change them.

Bob wrote:

Is there a way in VBA to disable the "Row and column headers" option within
the Tools | Options... | View tab menu so that a user cannot check (or
uncheck) the checkbox? I would like to do this without having to create a
custom toolbar or menu.

Thanks in advance for any guidance.

--

Dave Peterson


--

Dave Peterson


--

Dave Peterson
  #7   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3,986
Default Disabling row and column headers option

It might be a bit of overkill, but if you did the DisplayHeadings = False and
then
deleted the ToolsOptions from the menu, would it serve your purpose. Of
course, you would have to put it back at the end of the macro, because it
would otherwise carry over to any subsequent instance of Excel. But it would
make it difficult for a novice to restore the headings, since the check box
would be inaccessible untile the menu item was restored.

"Bob" wrote:

Dave,
As a second option, I guess I could do something like:

Private Sub Worksheet_Activate()
ActiveWindow.DisplayHeadings = False
End Sub

Thanks again for all your help and advice.
Bob


"Dave Peterson" wrote:

Nope. I can't.

You don't have that kind of granular control over the dialogs in excel.

In my USA version of Excel, I could use a line like this:

With Application.CommandBars("worksheet menu bar").Controls("Tools")
'.enabled or .visible????
.Controls("Options...").Enabled = False
End With

to try to prevent users from clicking on Tools|Options...

But if they reset the toolbar or disabled macros, then it would not work very
well!

Bob wrote:

Dave,

What I want to do is click on the "Row and column headers" checkbox so that
the row and column headers are not displayed. Then I want to prevent users
from re-displaying the row and column headers (i.e., unchecking the checkbox).

Can you tell me how to disable the "Row and column headers" checkbox in VBA?

Thanks,
Bob

"Dave Peterson" wrote:

I don't think you can change any of those built-in dialogs.

You can disable them, but you can't change them.

Bob wrote:

Is there a way in VBA to disable the "Row and column headers" option within
the Tools | Options... | View tab menu so that a user cannot check (or
uncheck) the checkbox? I would like to do this without having to create a
custom toolbar or menu.

Thanks in advance for any guidance.

--

Dave Peterson


--

Dave Peterson

  #8   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3,986
Default Disabling row and column headers option

Basically, that's what Dave's code does. But he didn't mention restoring it
before closing the program.

"Bob" wrote:

Dave,
As a second option, I guess I could do something like:

Private Sub Worksheet_Activate()
ActiveWindow.DisplayHeadings = False
End Sub

Thanks again for all your help and advice.
Bob


"Dave Peterson" wrote:

Nope. I can't.

You don't have that kind of granular control over the dialogs in excel.

In my USA version of Excel, I could use a line like this:

With Application.CommandBars("worksheet menu bar").Controls("Tools")
'.enabled or .visible????
.Controls("Options...").Enabled = False
End With

to try to prevent users from clicking on Tools|Options...

But if they reset the toolbar or disabled macros, then it would not work very
well!

Bob wrote:

Dave,

What I want to do is click on the "Row and column headers" checkbox so that
the row and column headers are not displayed. Then I want to prevent users
from re-displaying the row and column headers (i.e., unchecking the checkbox).

Can you tell me how to disable the "Row and column headers" checkbox in VBA?

Thanks,
Bob

"Dave Peterson" wrote:

I don't think you can change any of those built-in dialogs.

You can disable them, but you can't change them.

Bob wrote:

Is there a way in VBA to disable the "Row and column headers" option within
the Tools | Options... | View tab menu so that a user cannot check (or
uncheck) the checkbox? I would like to do this without having to create a
custom toolbar or menu.

Thanks in advance for any guidance.

--

Dave Peterson


--

Dave Peterson

  #9   Report Post  
Posted to microsoft.public.excel.programming
Bob Bob is offline
external usenet poster
 
Posts: 972
Default Disabling row and column headers option

Thanks for the suggestion. However, I would prefer to not mess with the menus.


"JLGWhiz" wrote:

Basically, that's what Dave's code does. But he didn't mention restoring it
before closing the program.

"Bob" wrote:

Dave,
As a second option, I guess I could do something like:

Private Sub Worksheet_Activate()
ActiveWindow.DisplayHeadings = False
End Sub

Thanks again for all your help and advice.
Bob


"Dave Peterson" wrote:

Nope. I can't.

You don't have that kind of granular control over the dialogs in excel.

In my USA version of Excel, I could use a line like this:

With Application.CommandBars("worksheet menu bar").Controls("Tools")
'.enabled or .visible????
.Controls("Options...").Enabled = False
End With

to try to prevent users from clicking on Tools|Options...

But if they reset the toolbar or disabled macros, then it would not work very
well!

Bob wrote:

Dave,

What I want to do is click on the "Row and column headers" checkbox so that
the row and column headers are not displayed. Then I want to prevent users
from re-displaying the row and column headers (i.e., unchecking the checkbox).

Can you tell me how to disable the "Row and column headers" checkbox in VBA?

Thanks,
Bob

"Dave Peterson" wrote:

I don't think you can change any of those built-in dialogs.

You can disable them, but you can't change them.

Bob wrote:

Is there a way in VBA to disable the "Row and column headers" option within
the Tools | Options... | View tab menu so that a user cannot check (or
uncheck) the checkbox? I would like to do this without having to create a
custom toolbar or menu.

Thanks in advance for any guidance.

--

Dave Peterson


--

Dave Peterson

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
VBE Options: Disabling Debug Option on All Errors JGS Excel Programming 1 December 4th 05 10:05 PM
Disabling the option to move cells programatically Devin Linnington Excel Programming 6 July 22nd 05 03:29 AM
Disabling macros is not an option! Paul Wagstaff Excel Programming 13 May 6th 05 05:16 PM
How can I set margins for headers on charts. The margin option ap. sayles1986 Charts and Charting in Excel 1 March 29th 05 10:57 AM
Option buttons - disabling Ann Excel Programming 1 July 23rd 03 01:04 AM


All times are GMT +1. The time now is 07:42 PM.

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"