Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1,560
Default Forms menu button question

Greetings and TIA for your time
I am using forms menu butons on Chart sheets to fire macros. All is well
until the user groups these sheets and then tries to press the button -
nothing happens, no macro is fired. I would like to message the user "please
ungroup sheets before pressing this button"
I've thought of including the message in the button text but this seems a
bit clumsy. Is there a better solution?
--
David
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 35,218
Default Forms menu button question

Option Explicit
Sub testme06()
If ActiveWindow.SelectedSheets.Count 1 Then
MsgBox "nope, nope, nope"
Exit Sub
End If
End Sub

David wrote:

Greetings and TIA for your time
I am using forms menu butons on Chart sheets to fire macros. All is well
until the user groups these sheets and then tries to press the button -
nothing happens, no macro is fired. I would like to message the user "please
ungroup sheets before pressing this button"
I've thought of including the message in the button text but this seems a
bit clumsy. Is there a better solution?
--
David


--

Dave Peterson
  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1,560
Default Forms menu button question

Dave,
Thanks for your response
I,m still left with the same problem though...
My user is free to navigate around the workbook, print off a group of sheets
etc. When he has a group of sheets selected and then attempts to press a
button on a chart sheet, no macro will fire (buttons on chart sheets appear
to be dead when sheet is grouped) I need to tell him at that point for that
particular scenario only, that he needs to ungroup sheets before pressing the
button

"Dave Peterson" wrote:

Option Explicit
Sub testme06()
If ActiveWindow.SelectedSheets.Count 1 Then
MsgBox "nope, nope, nope"
Exit Sub
End If
End Sub

David wrote:

Greetings and TIA for your time
I am using forms menu butons on Chart sheets to fire macros. All is well
until the user groups these sheets and then tries to press the button -
nothing happens, no macro is fired. I would like to message the user "please
ungroup sheets before pressing this button"
I've thought of including the message in the button text but this seems a
bit clumsy. Is there a better solution?
--
David


--

Dave Peterson

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 35,218
Default Forms menu button question

I created a multi-sheet workbook. I put a button from the forms toolbar on a
chart sheet. I assigned it my test macro.

I grouped a bunch of sheets with that chart sheet active. I pushed that button
and got "nope, nope, nope" back.

I used xl2003--if you used something else, maybe someone can test it. (I would
still expect it to work fine, though.)

David wrote:

Dave,
Thanks for your response
I,m still left with the same problem though...
My user is free to navigate around the workbook, print off a group of sheets
etc. When he has a group of sheets selected and then attempts to press a
button on a chart sheet, no macro will fire (buttons on chart sheets appear
to be dead when sheet is grouped) I need to tell him at that point for that
particular scenario only, that he needs to ungroup sheets before pressing the
button

"Dave Peterson" wrote:

Option Explicit
Sub testme06()
If ActiveWindow.SelectedSheets.Count 1 Then
MsgBox "nope, nope, nope"
Exit Sub
End If
End Sub

David wrote:

Greetings and TIA for your time
I am using forms menu butons on Chart sheets to fire macros. All is well
until the user groups these sheets and then tries to press the button -
nothing happens, no macro is fired. I would like to message the user "please
ungroup sheets before pressing this button"
I've thought of including the message in the button text but this seems a
bit clumsy. Is there a better solution?
--
David


--

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
Create floating button based on button click in menu ExcelMonkey Excel Programming 2 October 12th 05 06:43 PM
Forms Toolbar Button question reddog9069[_6_] Excel Programming 4 July 25th 05 02:23 AM
Formsbutton question Stuart[_21_] Excel Programming 2 May 5th 05 09:42 PM
why are the options on my forms menu greyed out? MarkFromBristol Excel Programming 2 October 8th 04 11:56 PM
Menu for user forms Hank Hendrix Excel Programming 4 June 7th 04 03:51 PM


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