Is that possible? :rolleyes: I want the text to be in the center of the combobox, rather than the default align which is left...
Printable View
Is that possible? :rolleyes: I want the text to be in the center of the combobox, rather than the default align which is left...
You could use the padleft method of a string to make it appear centered. It's a pretty weak work around but....
VB Code:
Dim sTest As String sTest = "Centered" cboTest.Items.Add(sTest.PadLeft(((cboTest.DropDownWidth / 3) - Len(sTest)) / 2))
oh well, it's pretty stupid if there isnt a good way to do this, hehe :D
tnx for the code :)