home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
DP Tool Club 26
/
CD_ASCQ_26_1295.iso
/
vrac
/
mlist460.zip
/
MLIST.BAS
< prev
next >
Wrap
BASIC Source File
|
1995-09-04
|
715b
|
30 lines
Option Explicit
Sub MListItemsResize (mlst As MListBox, ByVal viHeight As Integer)
Dim i As Integer
' create an array large enough to hold the contents of the MList
ReDim msItem(mlst.ListCount - 1) As String
' copy the items from the MList to the array
For i = 0 To UBound(msItem)
msItem(i) = mlst.List(i)
Next i
mlst.Clear
' mlst.Refresh
' setting the ItemHeight property for an MList
' will resize every line in the MList when it is reloaded!
mlst.AddItemHeight = viHeight
' now reload the listbox from the array
For i = 0 To UBound(msItem)
mlst.AddItem msItem(i)
Next i
Erase msItem
End Sub