Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Additems in combo box.
Message
From
17/08/1999 09:28:34
 
 
To
16/08/1999 20:28:09
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Miscellaneous
Thread ID:
00254359
Message ID:
00254484
Views:
19
>>I have an idea what I am doing wrong, but not sure what is the way to correct it. In my form activate I have code like:
>>
>>thisform.combo1.additem("First choice")
>>thisform.combo1.additem("Second choice")
>>thisform.combo1.additem("Third choice")
>>
>>My problem is choices seem to be duplicating. I think I need to put the code somewhere else? Am I doing anything else wrong?
>>
>>TIA
>>Jim
>
>Try the form init.

Every time the form gets activated your code will run, thus, duplicating your values. If possible, put the code in the control's init event. That way, you will be taking advantage of encapsulation.
Previous
Reply
Map
View

Click here to load this message in the networking platform