Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Is ListBox Okay?
Message
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00272435
Message ID:
00272437
Views:
27
>I have some routines that programtically evaluate the contents of a listbox. Sometimes they miss!
>All ListItems are Upper case and all searches are upper case:
>Examples of only partial successes:
>
>To check for an item existing in a listbox:
>myform.mylist.value=mystring
>Even though mystring equals the list.value, List index returns 0.
>
>So, thinking that point request is too quick for list box, the following OVER process was implemented:
>
>myform.mylist.listindex=myform.mylist.listindex && Wanna be sure
>for myform.mylist.listindex=1 to myform.mylist.listcount
>if myform.mylist.listitem(myform.mylist.listindex)=mystring
> myform.mylist.value=mystring
> myform.mylist.listindex=myform.mylist.listindex && Make sure the point points!
> exit
>endif
>Endfor
>
>Even the overkill method misses on occasion. Is there something else I need to be doing. Should I use some other control?
>
Hi Terry,

I've never heard of anyone trying to use a FOR...ENDFOR to increment the list index. Have you tried using a memvar in the loop, instead?
George

Ubi caritas et amor, deus ibi est
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform