![]() |
Macro button on one sheet only
Hi,
when I create a button and place it on the toolbar and then assign a macro to it, is it possible to have that button display on the toolbar in the one sheet it was intended for only and no other sheet? Thanks, Noel |
Macro button on one sheet only
Wouldn't it be easier to insert a row at the top of your sheet, put the
macro button on this row and then freeze the pane? "Nleric" wrote in message ... Hi, when I create a button and place it on the toolbar and then assign a macro to it, is it possible to have that button display on the toolbar in the one sheet it was intended for only and no other sheet? Thanks, Noel |
Macro button on one sheet only
Why not just put the button on the sheet??
-- Don Guillett SalesAid Software "Nleric" wrote in message ... Hi, when I create a button and place it on the toolbar and then assign a macro to it, is it possible to have that button display on the toolbar in the one sheet it was intended for only and no other sheet? Thanks, Noel |
Macro button on one sheet only
Alternatively you could use something like the following:-
First Create a toolbar called MyMacros, then assign your button to that toolbar, Then lets say that the sheet you want the toolbar to display when activated is called mymacros_sheet. Private Sub Workbook_SheetActivate(ByVal Sh As Object) If Sh.name = "MyMacros_Sheet" Then Application.CommandBars("MyMacros").Visible = True Else Application.CommandBars("MyMacros").Visible = False End If End Sub HTH Andi "Don Guillett" wrote in message ... Why not just put the button on the sheet?? -- Don Guillett SalesAid Software "Nleric" wrote in message ... Hi, when I create a button and place it on the toolbar and then assign a macro to it, is it possible to have that button display on the toolbar in the one sheet it was intended for only and no other sheet? Thanks, Noel |
Macro button on one sheet only
Thanks for the replies, I am new to this and was having a Homer Simpson
moment :-))) Noel "Andibevan" wrote: Alternatively you could use something like the following:- First Create a toolbar called MyMacros, then assign your button to that toolbar, Then lets say that the sheet you want the toolbar to display when activated is called mymacros_sheet. Private Sub Workbook_SheetActivate(ByVal Sh As Object) If Sh.name = "MyMacros_Sheet" Then Application.CommandBars("MyMacros").Visible = True Else Application.CommandBars("MyMacros").Visible = False End If End Sub HTH Andi "Don Guillett" wrote in message ... Why not just put the button on the sheet?? -- Don Guillett SalesAid Software "Nleric" wrote in message ... Hi, when I create a button and place it on the toolbar and then assign a macro to it, is it possible to have that button display on the toolbar in the one sheet it was intended for only and no other sheet? Thanks, Noel |
All times are GMT +1. The time now is 11:46 AM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com