![]() |
Custom Toolbar position
I have the follwoing code that creates a toolbar when the
workbook is open. What I want to do is to make it show up at the top of the screen not right in the middle where it does now. Help Application.CommandBars.Add(Name:="COUNT").Visible = True Application.CommandBars("COUNT").Controls.Add Type:=msoControlButton, ID:=3 _ , Befo=1 Application.CommandBars("COUNT").Controls.Add Type:=msoControlButton, ID:= _ 752, Befo=2 |
Custom Toolbar position
Application.CommandBars.Add(Name:="COUNT").Top = 0
would put it at the top of the screen -- Regards, Tom Ogilvy "Michelle" wrote in message ... I have the follwoing code that creates a toolbar when the workbook is open. What I want to do is to make it show up at the top of the screen not right in the middle where it does now. Help Application.CommandBars.Add(Name:="COUNT").Visible = True Application.CommandBars("COUNT").Controls.Add Type:=msoControlButton, ID:=3 _ , Befo=1 Application.CommandBars("COUNT").Controls.Add Type:=msoControlButton, ID:= _ 752, Befo=2 |
Custom Toolbar position
That puts it at the top, but I would like it to be
positioned at the topleft where the starndard toolbar would have been had I not hidden it. You would see the name of the file then the toolbar set in postiton like a normal tool bar. If I have you lost I am sorry -----Original Message----- Application.CommandBars.Add(Name:="COUNT").Top = 0 would put it at the top of the screen -- Regards, Tom Ogilvy "Michelle" wrote in message ... I have the follwoing code that creates a toolbar when the workbook is open. What I want to do is to make it show up at the top of the screen not right in the middle where it does now. Help Application.CommandBars.Add(Name:="COUNT").Visible = True Application.CommandBars("COUNT").Controls.Add Type:=msoControlButton, ID:=3 _ , Befo=1 Application.CommandBars("COUNT").Controls.Add Type:=msoControlButton, ID:= _ 752, Befo=2 . |
Custom Toolbar position
thought it was a floating toolbar:
Sub BBBB() On Error Resume Next Application.CommandBars("COUNT").Delete On Error GoTo 0 Application.CommandBars.Add(Name:="COUNT", _ Position:=msoBarTop, MenuBar:=True).Visible = True Application.CommandBars("COUNT").Controls.Add _ Type:=msoControlButton, ID:=3, Befo=1 Application.CommandBars("COUNT").Controls.Add _ Type:=msoControlButton, ID:=752, Befo=2 End Sub delete COUNT to get the worksheet menu bar back. -- Regards, Tom Ogilvy wrote in message ... That puts it at the top, but I would like it to be positioned at the topleft where the starndard toolbar would have been had I not hidden it. You would see the name of the file then the toolbar set in postiton like a normal tool bar. If I have you lost I am sorry -----Original Message----- Application.CommandBars.Add(Name:="COUNT").Top = 0 would put it at the top of the screen -- Regards, Tom Ogilvy "Michelle" wrote in message ... I have the follwoing code that creates a toolbar when the workbook is open. What I want to do is to make it show up at the top of the screen not right in the middle where it does now. Help Application.CommandBars.Add(Name:="COUNT").Visible = True Application.CommandBars("COUNT").Controls.Add Type:=msoControlButton, ID:=3 _ , Befo=1 Application.CommandBars("COUNT").Controls.Add Type:=msoControlButton, ID:= _ 752, Befo=2 . |
All times are GMT +1. The time now is 11:43 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com