![]() |
Toolbar Button Coordinates
My custom toolbar has a button that brings up a userform. I want the
userform to be centered horizontally over the button. Thing is, the toolbar may be moved around or be displayed on PCs with widescreen monitors, etc. How do I determine how to center the userform over the button? TIA, James |
Toolbar Button Coordinates
http://www.cpearson.com/excel/FormPosition.htm
that is for a cell, but the button has a cell under it (topleftcell attribue). -- Regards, Tom Ogilvy "Zone" wrote in message ... My custom toolbar has a button that brings up a userform. I want the userform to be centered horizontally over the button. Thing is, the toolbar may be moved around or be displayed on PCs with widescreen monitors, etc. How do I determine how to center the userform over the button? TIA, James |
Toolbar Button Coordinates
On Mar 24, 3:53�pm, "Tom Ogilvy" wrote:
http://www.cpearson.com/excel/FormPosition.htm that is for a cell, but the button has a cell under it * (topleftcell attribue). -- Regards, Tom Ogilvy "Zone" wrote in message ... My custom toolbar has a button that brings up a userform. *I want the userform to be centered horizontally over the button. *Thing is, the toolbar may be moved around or be displayed on PCs with widescreen monitors, etc. How do I determine how to center the userform over the button? *TIA, James- Hide quoted text - - Show quoted text - Thanks, Tom! What syntax do I use to get the address of the cell under the 6th button on toolbar "mytb"? James |
Toolbar Button Coordinates
I guess I didn't read closely enough and assumed a button on a sheet. for a
commandbar, you can get the location: (to illustrate from the immediate window) ? application.CommandBars("Mytb").Controls(r).Top 60 it also has attributes for Left, Height and Width -- Regards, Tom Ogilvy "Zone" wrote in message oups.com... On Mar 24, 3:53?pm, "Tom Ogilvy" wrote: http://www.cpearson.com/excel/FormPosition.htm that is for a cell, but the button has a cell under it (topleftcell attribue). -- Regards, Tom Ogilvy "Zone" wrote in message ... My custom toolbar has a button that brings up a userform. I want the userform to be centered horizontally over the button. Thing is, the toolbar may be moved around or be displayed on PCs with widescreen monitors, etc. How do I determine how to center the userform over the button? TIA, James- Hide quoted text - - Show quoted text - Thanks, Tom! What syntax do I use to get the address of the cell under the 6th button on toolbar "mytb"? James |
All times are GMT +1. The time now is 05:36 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com