Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How can I programmatically click an item in a combobox?
Message
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00353058
Message ID:
00353063
Views:
17
>I have a combobox with items in a drop-down list. When I click the first item in the list, I get the proper record displayed on my form. That works. But how can I have the form do the combobox click for me at Form Init time so the same first record in the combobox appears without me clicking on it in the drop-down list using my mouse.
>
>I tried -
>
>THISFORM.myCombobox.ListIndex = 1
>THISFORM.myCombobox.Click()
>THISFORM.Refresh
>
>but not working. What am I forgetting? Thanks for the help.
:
Try
THISFORM.myCombobox.ListIndex = 1
THISFORM.myCombobox.displayvalue='My value'
If it's not broken, fix it until it is.


My Blog
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform