home *** CD-ROM | disk | FTP | other *** search
/ Programming Tool Box / SIMS_2.iso / access / diverses / expdli / expdlist.txt < prev   
Text File  |  1995-02-27  |  776b  |  23 lines

  1.  
  2.  
  3. Auto Expand List box
  4.  
  5.  
  6. This example uses a binary search to find the target in the
  7. ItemData property of the list.  It assumes the list is sorted 
  8. in ascending order.  The search is triggered by the form's timer
  9. event once every second.  A search is only done if the SearchVal
  10. has changed.
  11.  
  12. The SearchVal is built in the KeyPress and KeyUp events of the 
  13. txtSearch text box.  I have attempted to cover every combination
  14. of changing the text box, including selecting a substring with the
  15. mouse and typing over it.  The example list contains over 
  16. 2000 string elements.  The first search is a bit slow, but it is
  17. fast after that.  Any comments, negative, positive, or how to improve
  18. it, would be greatly appreciated.
  19.  
  20.  
  21. Jim Davis
  22.  
  23. jddavis@cs.washington.edu