Click to See Complete Forum and Search --> : Combo box empties upon leaving click_event.
Chuck Sweet
Jan 6th, 2000, 10:39 PM
Allright, here's the problem. In a activex control, i modify the text property of a combo box. this modification is triggered by a procedure call from a property set subroutine in the control. When stepping through, the data appears in the control up to the point that the end of the clicked event is reached (aka. the End Sub). then, when that is stepped over, the data dissappears. if you have any ideas, please let me know.
------------------
To err is human, but to apologize frequently is embarassing.
Chuck Sweet
Jan 7th, 2000, 03:59 AM
FYI: I solved the problem I posted earlier. In a combo box, you cannot change the .text property from the clicked_event if you clear the list portion in the clicked event as well. ie.
Public Sub combo1_clicked()
combo1.clear
'data is an array of strings
for i = 0 to ubound(data)
combo1.additem data(i)
next i
combo1.text = "TestData"
End Sub
the result is:
1. list gets cleared
2. list gets repopulated
3. text gets set
4. when sub ends, text gets cleared
i don't know why this happens. if someone wants to explain why, please let me know.
Chuck Sweet
------------------
To err is human, but to apologize frequently is embarassing.
vbforums.com
Copyright Internet.com Inc., All Rights Reserved.