Hi Guys
I need procedure to fit columns in listbox without specify values . should expand and contracts and control margins for width based on size of data for each column.
so when run the userform or search for data should autofill columns in listbox
I look forward to add some procedures to do that
I need procedure to fit columns in listbox without specify values . should expand and contracts and control margins for width based on size of data for each column.
so when run the userform or search for data should autofill columns in listbox
I look forward to add some procedures to do that
VBA Code:
Private Sub UserForm_Initialize()
Dim LastRow As Long
Set sh = ActiveSheet
a = sh.Range("A1:F" & sh.Range("A" & Rows.Count).End(xlUp)).Value
With MY_List
.ColumnCount = 7
.ColumnWidths = "20;50;100;100;70;70;70"
Call CommandButton4_Click
End With
End Sub
thanks