Question : How do I create a 'change' event for a VB6 listbox control?

I have a VB6 listbox that holds 4 names (max) at any one time. However, not every position in the listbox has a name at any one time-----the asterisks ( * ) are 'place holders' for blank list positions. For example, the listbox list will look like this at times:

R. Jones
M. Hallem

......other times it will look like this:

J. Holt

The ListBox control in VB6 has no 'change' event that I can find....
How do I track the appearance of a name at index position (0) whenever the listbox content is 'changed' by adding a new item at the bottom and removing the top item?

Something like this:

Sub ListBox1_Change()

      If Not ListBox1.TopIndex = "*" Then

            'do something here with code...

      End If

End Sub

Thanks for any help....

Answer : How do I create a 'change' event for a VB6 listbox control?

One way woudl be to use the Timer control. You could put a timer on the form with an interval of 1000, which equals 1 second. Of course, you could make it shorter, like 500 for every half second. Then  you could put the code in that. Be sure to enable the Timer control.
Random Solutions  
programming4us programming4us