How to Use IncrementalSearch Property of List and Combo Boxes (137125)



The information in this article applies to:

  • Microsoft Visual FoxPro for Windows 3.0

This article was previously published under Q137125

SUMMARY

The IncrementalSearch property of list and combo boxes permit the user to perform an incremental search of values. An example of an incremental search would be to type the letter F followed by the letter O, and find the first occurrence of a string beginning with FO. A non-incremental search in this case would first locate the first string beginning with F, followed by the first string beginning with the letter O.

The IncrementalSearch property enables or disables this capability within list and combo boxes. However, by itself, the IncremetalSearch property set to True may not always produce what you expect.

MORE INFORMATION

To take advantage of the IncrementalSearch property, the _DBLCLICK variable must also be set. The initial value of .5 for _DBLCLICK may not provide adequate time to enter the characters in the object. Increasing the value of _DBLCLICK to 1.5 allows more time to enter data.

Therefore, in the Init event of a formset, form, list box, or combo box, add this line of code:
   _DBLCLICK=1.5
					
Then set the IncrementalSearch property of the list or combo box to true, and the incremental search behavior will work as expected.

Modification Type:MajorLast Reviewed:8/16/2006
Keywords:KB137125