cresbydotcom
Technical User
- May 22, 2006
- 234
After loosing toolbars regularly due to re-boots after lock-out when powered down (it is an ATI TV app bug!) this routine was devised to re-instate a toolbar with consistent parameters. The routines reside in fred.xls & not in the Active.Workbook. The real toolbar is much more comprehensive.
relevant FAQ
Code:
Private Sub retool_Click()
'This macro generates a tool bar called 'local' and gives it specific properties
Application.CommandBars.Add(Name:="local").Visible = True
Application.CommandBars("local").Controls.Add Type:=msoControlButton, _
ID:= 2950, Before:=1
With Application.CommandBars("local").Controls.Item(1)
.Caption = "TV"
.Style = msoButtonCaption
.OnAction = "'C:\My Documents\fred.xls'!runTV"
End With
Application.CommandBars("local").Controls.Add Type:=msoControlButton_
ID:= 2950, Before:=2
With Application.CommandBars("local").Controls.Item(2)
.Caption = "Dance"
.Style = msoButtonCaption
.OnAction = "'C:\My Documents\fred.xls'!rundance"
End With
End Sub