Re: INPUT not saving values on ACCEPT
Posted in 1994
In <zorbaCJ9JEx.63s@netcom.com> zorba@netcom.com (Harry Skelton) writes: > Is this a bug?: > On an input statement, I have the ACCEPT key defined as ESCAPE. I enter a > value on the screen and press ESCAPE but the value is not passed to the > varable that is due to hold it!! Only if I hit return can I 'save' the > value prior to ACCEPT. I always grouse when I have to work around this too. I don't see any reason it could be considered a feature, so let's call it a bug and see who rises to its defense :-) > Is there a way to setup INPUT to save the value when ACCEPT it hit or a > way for me to 'peek' at the value and pull it from Informix after the > ACCEPT. (i.e. is it stored in some temp variable that Informix makes for > the field reference. > Lastly, is there a way I can fetch a screen value without looking at the > variable defined for the screen? i.e. LET var = screen.field1 sort of > thing? Both in the same: let var = get_fldbuf(field1) such as: options accept key control-A # to get rid of it input... on key (ESCAPE) let var = get_fldbuf(field1) exit input (also, call get_fldbuf(field1, f2, f3) returning var1, v2, v3.) I've also found numerous related bugs, e.g., in one case I have input... after field f1 ...compute new f2 base on f1... display by name f2 and, though it does display f2 on the screen, if I do a get_fldbuf(f2) etc. I get the *OLD* f2 value! Argh. My kludge is to add next field f2 which somehow works around the bug (i.e., the new value is "seen" once the cursor enters the field). IMHO, the whole forms package should be pitched and rewritten. It may have been revolutionary in its day, but it's antiquated and creaking now. -- Andrew Burt aburt@du.edu "But if he was dying he wouldn't bother to carve "Aaaaargh", he'd just say it."