Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hi All
I have a listbox with 3 columns. The first 2 have their width set to 0 and the third is left to default i.e. size itself (theorectically). The problem i'm having is that even though the contents of the 3rd column are greater than the width of the listbox the horizontal scrollbar is not being displayed. Does anyone have any ideas on this? The code i'm using to fill the listbox is: Do Until ADOrecordset.EOF lstAvailable.AddItem lstAvailable.Column(0, intcount) = ADOrecordset! ClientWorkID lstAvailable.Column(1, intcount) = ADOrecordset! WorkTypeCat lstAvailable.Column(2, intcount) = CStr(ADOrecordset! ClientName & " " & ADOrecordset!SchemeDesc & " " & ADOrecordset! WorkDesc & IIf(ADOrecordset!WorkTypeCat = 0, " (B)", " (F)")) ADOrecordset.MoveNext intcount = intcount + 1 Loop cheers Keith |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Don't know if this will help or not, but this is from the VBA help files.
Values for the TextColumn property range from €“1 to the number of columns in the list. The TextColumn value for the first column is 1, the value of the second column is 2, and so on. Setting TextColumn to 0 displays the ListIndex values. Setting TextColumn to €“1 displays the first column that has a ColumnWidths value greater than 0. If all else fails, reset the width of the listbox so that the column shows without a need for a scrollbar. "Keith74" wrote: Hi All I have a listbox with 3 columns. The first 2 have their width set to 0 and the third is left to default i.e. size itself (theorectically). The problem i'm having is that even though the contents of the 3rd column are greater than the width of the listbox the horizontal scrollbar is not being displayed. Does anyone have any ideas on this? The code i'm using to fill the listbox is: Do Until ADOrecordset.EOF lstAvailable.AddItem lstAvailable.Column(0, intcount) = ADOrecordset! ClientWorkID lstAvailable.Column(1, intcount) = ADOrecordset! WorkTypeCat lstAvailable.Column(2, intcount) = CStr(ADOrecordset! ClientName & " " & ADOrecordset!SchemeDesc & " " & ADOrecordset! WorkDesc & IIf(ADOrecordset!WorkTypeCat = 0, " (B)", " (F)")) ADOrecordset.MoveNext intcount = intcount + 1 Loop cheers Keith |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Unwanted Listbox Horizontal Scrollbar | Excel Programming | |||
Horizontal Scrollbar | New Users to Excel | |||
Needless Horizontal scrollbar in Listbox | Excel Programming | |||
Horizontal Scrollbar For Lisbox | Excel Programming | |||
Horizontal scrollbar in ListBox | Excel Programming |