home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1993 #3 / NN_1993_3.iso / spool / comp / database / 9479 < prev    next >
Encoding:
Text File  |  1993-01-28  |  2.1 KB  |  70 lines

  1. Newsgroups: comp.databases
  2. Path: sparky!uunet!ukma!gatech!emory!swrinde!ringer!lonestar.utsa.edu!moursand
  3. From: moursand@lonestar.utsa.edu (Bowen M. Moursund)
  4. Subject: Re: dBASE IV problem
  5. Message-ID: <1993Jan26.231235.27322@ringer.cs.utsa.edu>
  6. Sender: news@ringer.cs.utsa.edu
  7. Nntp-Posting-Host: lonestar.utsa.edu
  8. Organization: University of Texas at San Antonio
  9. References: <1993Jan21.212859.20703@cs.wm.edu>
  10. Distribution: na
  11. Date: Tue, 26 Jan 1993 23:12:35 GMT
  12. Lines: 56
  13.  
  14. In article <1993Jan21.212859.20703@cs.wm.edu> weiss@cs.wm.edu (David W. Weiss) writes:
  15. >
  16. >
  17. >Following are a couple of procedures from a dBASE program
  18. >I wrote. It is part of a screen where a user enters some
  19. >information into memory variables. It issupposed to allow
  20. >the user to hit F1 and get a pop-up window of possible values
  21. >and then select one value from that window. It works great if
  22. >they just type a value directly into the field or type nothing
  23. >in the field and just select a value using the pop-up window.
  24. >However, if they start to type something in the field and then
  25. >instead use the pop-up window and select a value the variable
  26. >will contain the typed value instead of what was selected from
  27. >the window. I think it has something to do with how the READ
  28. >command works but I haven't been able to get around it.
  29. >Any suggestions or am I out of luck.
  30. >
  31. >
  32. >
  33. >PROCEDURE Getrest
  34. >ON KEY LABEL F1 DO FieldHelp
  35. >@ 12,25 GET mLocality PICTURE "!!" ;
  36. >  MESSAGE "Press <F1> to see Localitys lookup list" COLOR B/W
  37. >READ
  38. >ON KEY
  39. >RETURN
  40. >
  41. >PROCEDURE Fieldhelp
  42. >USE Localitys
  43. >DEFINE POPUP Locs FROM 11,28 TO 17,60 MESSAGE;
  44. >  "Use up and down arrow keys to highlight menu choice and press <Enter>"
  45. >n = 1
  46. >SCAN
  47. >    DEFINE BAR n OF Locs PROMPT Locality + " " + Loctext
  48. >    n = n + 1
  49. >ENDSCAN
  50. >ON SELECTION POPUP Locs DO Locselect
  51. >ACTIVATE POPUP Locs
  52. >@ 12,25 SAY mLocality COLOR GR+/W
  53. >CLOSE DATABASES
  54. >RETURN
  55. >
  56. >PROCEDURE Locselect
  57. >GOTO BAR()
  58. >mLocality = Locality
  59. >DEACTIVATE POPUP
  60. >RETURN
  61.  
  62. Dave: Try something like this:
  63.  
  64. PROCEDURE LocSelect
  65. keyboard chr(26)+chr(25)+right(prompt(),2)
  66. deactivate popup
  67. RETURN
  68.  
  69.  
  70.