home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.databases
- Path: sparky!uunet!haven.umd.edu!darwin.sura.net!ms!weiss
- From: weiss@cs.wm.edu (David W. Weiss)
- Subject: dBASE IV problem
- Message-ID: <1993Jan21.212859.20703@cs.wm.edu>
- Sender: news@cs.wm.edu (News System)
- Nntp-Posting-Host: ga.cs.wm.edu
- Organization: The College of William and Mary
- Distribution: na
- Date: Thu, 21 Jan 1993 21:28:59 GMT
- Lines: 56
-
-
-
- Following are a couple of procedures from a dBASE program
- I wrote. It is part of a screen where a user enters some
- information into memory variables. It issupposed to allow
- the user to hit F1 and get a pop-up window of possible values
- and then select one value from that window. It works great if
- they just type a value directly into the field or type nothing
- in the field and just select a value using the pop-up window.
- However, if they start to type something in the field and then
- instead use the pop-up window and select a value the variable
- will contain the typed value instead of what was selected from
- the window. I think it has something to do with how the READ
- command works but I haven't been able to get around it.
- Any suggestions or am I out of luck.
-
-
-
- PROCEDURE Getrest
- ON KEY LABEL F1 DO FieldHelp
- @ 12,25 GET mLocality PICTURE "!!" ;
- MESSAGE "Press <F1> to see Localitys lookup list" COLOR B/W
- READ
- ON KEY
- RETURN
-
- PROCEDURE Fieldhelp
- USE Localitys
- DEFINE POPUP Locs FROM 11,28 TO 17,60 MESSAGE;
- "Use up and down arrow keys to highlight menu choice and press <Enter>"
- n = 1
- SCAN
- DEFINE BAR n OF Locs PROMPT Locality + " " + Loctext
- n = n + 1
- ENDSCAN
- ON SELECTION POPUP Locs DO Locselect
- ACTIVATE POPUP Locs
- @ 12,25 SAY mLocality COLOR GR+/W
- CLOSE DATABASES
- RETURN
-
- PROCEDURE Locselect
- GOTO BAR()
- mLocality = Locality
- DEACTIVATE POPUP
- RETURN
-
-
- -------------------------------------------------------
-
- Thanks a lot,
-
- Dave
- weiss@cs.wm.edu
-
-
-