Keep List Box from Jumping to First Entry Beg w/ 2nd Char

Last reviewed: October 5, 1995
Article ID: Q95674
The information in this article applies to:
  • Microsoft FoxPro for Windows, version 2.5
  • Microsoft FoxPro for MS-DOS, versions 2.0 and 2.5

SUMMARY

The _DBLCLICK variable can be used to increase the efficiency of searching through a sorted list box. For example, to search a list box for all entries beginning with the characters "SC", the setting of the _DBLCLICK variable determines if the second keystroke, "C", will bring the insertion point to entries beginning with "C" or "SC".

MORE INFORMATION

The _DBLCLICK variable is commonly used to check the intervals between mouse double-clicks and triple-clicks. It can also be used to check the intervals between keystrokes. _DBLCLICK can range from 0.5 to 5.5 (seconds). The default value is 0.5.

The following steps illustrate the keyboard use of _DBLCLICK:

  1. Make sure the FoxPro Help system is set to FOXHELP.DBF by issuing the following command in the Command window:

          SET HELP TO FOXHELP.DBF
    

  2. Make sure _DBLCLICK is set to the default value by issuing the following in the Command window:

          _DBLCLICK = 0.5
    

  3. In the Command window, type "HELP" (without the quotation marks) and press the ENTER key.

  4. Press S. (SAVE MACROS will be the highlighted entry.)

  5. Press C. (CALCULATE will be the highlighted entry.)

  6. In the Command window, issue the following command:

          _DBLCLICK = 2.5
    

  7. Return to the HELP window and repeat steps 3 and 4. (SCAN will be the highlighted entry.)

  8. Press H. (SCHEME will be the highlighted entry.)

NOTE: In an @ ... GET list, if _DBLCLICK is set to a high value in the WHEN clause and set back to the default in the VALID clause, it will not affect the double-click setting of the mouse in other fields.


Additional reference words: FoxDos FoxWin 2.00 2.50 keyboard delay one time
listbox character incremental search
KBCategory: kbprg
KBSubcategory: FxprgGeneral


THE INFORMATION PROVIDED IN THE MICROSOFT KNOWLEDGE BASE IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND. MICROSOFT DISCLAIMS ALL WARRANTIES, EITHER EXPRESS OR IMPLIED, INCLUDING THE WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL MICROSOFT CORPORATION OR ITS SUPPLIERS BE LIABLE FOR ANY DAMAGES WHATSOEVER INCLUDING DIRECT, INDIRECT, INCIDENTAL, CONSEQUENTIAL, LOSS OF BUSINESS PROFITS OR SPECIAL DAMAGES, EVEN IF MICROSOFT CORPORATION OR ITS SUPPLIERS HAVE BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. SOME STATES DO NOT ALLOW THE EXCLUSION OR LIMITATION OF LIABILITY FOR CONSEQUENTIAL OR INCIDENTAL DAMAGES SO THE FOREGOING LIMITATION MAY NOT APPLY.

Last reviewed: October 5, 1995
© 1998 Microsoft Corporation. All rights reserved. Terms of Use.