Re: i4gl 6.04.UC1 problem
Posted in 1997
In article <5svetv$s1u@cssun.mathcs.emory.edu>, Colin M McGrath <cmm@trac3000.ueci.com> wrote: |In an "input array" statement, the user can press a key that uses the |ON KEY control to call up a lookup function that displays a form, and |lets the user choose a valid selection for the field. The lookup |function returns the user's selection into the current field in the |current record in the program array and then it is displayed. Like: | |INPUT ARRAY w_det_arr WITHOUT DEFAULTS FROM scr_det_arr.* | ON KEY(F8) | CASE | WHEN INFIELD (pay_code) | CALL lookup("pay_code") | RETURNING w_det_arr[arrcurr].pay_code | DISPLAY w_det_arr[arrcurr].* TO | scr_det_arr[scrline].* | END CASE | |The problem is that Informix's default behavior is to restore the input |buffer for the current screen field after executing the statements in the |ON KEY block before resuming input in the same field. |This default behavior is supposed to be overridden if you change the |input buffer value for the current field by assigning a new value to the |corresponding variable, and then displaying this value. Which we do. Yes, your explanation is dead-on... and the DISPLAY should have taken care of it... |Workaround: |If the "*" in the TO side of the "DISPLAY ... TO ..." statement is replaced |by the list of fields in the record of the scr_det_arr, the program displays |the new value immediately. |... |Tech support feels bug 60072 is related, and is fixed in 4GL Vers 6.05.UD1. |We are waiting for it to arrive so we can compare. Based on the description and the fix data in PTS, I'd say that's likely. My guess is that I may well have introduced this one in 4.16/6.04 when rewriting the INPUT {ARRAY} control sequencing (bugs 2288, 12854, 18726, 42524, 43172, 45471, 35959, 42072, and countless dupes of those bugs). If so, sorry about that... but I guarantee you it was worse (at least, less consistent) before I got my hands on it... \\-: (IMHO, those who use versions 4.13-4.15 or 6.01-6.03 and do any meaningful INPUT work, you should really think about upgrading... yours was a rare case to actually work *better* under 4.13 than 6.04...) By the way: the intriguing little sub-behaviors of REQUIRED with INPUT and DISPLAY were largely undocumented *until* the release note that I wrote about this set of bugs -- be sure to read it if you haven't yet. (See TOOLREL_4.16 and TOOLREL_6.04) -- Alan Denney yosemite_at_netcom.com Speaking from, but not for, Informix Platform Engineering "My opinions may have changed, but not the fact that I am right." -- Ashleigh Brilliant