How to make all the buttons in toolbar have the same width?

mhmdh2000

Member
Joined
Sep 28, 2005
Messages
6
Programming Experience
5-10
After I added text properties to the buttons, each button has different width depending on its text. But I need all the buttons to have the same width.
 
Last edited:
set all the button's width equal to the largest button and there ya go

if you know which button is the largest already then a simple loop setting all the other button's widths would be easy and quick (plus flexible so it'll do it even if you add buttons in the designer later)
 
I can't find "width" property of the toolbar button:


Dim i As Int16

For i = 0 To ToolBar1.Buttons.Count - 1

ToolBar1.Buttons(i).width = 100 'No width property

Next


 
We Can Also Use Format

We can also accomplish this by selecting all the buttons and go to format menu->make same size -> width.
 
Back
Top