Anyway the RGPLE program can now if the enter it's cause by the CHECK(ER)?
Announcement
Collapse
No announcement yet.
Enter VS CHECK(ER)
Collapse
X
-
Re: Enter VS CHECK(ER)
No, There isn't a way to differentiate. Below I put a small program below that shows it. Whether actually pressing enter or letting CHECK(ER) simulate enter on field exit.
Code:A DSPSIZ(24 80 *DS3) A INDARA A R FMT1 A CF02(02 'ret') A CF03(03 'Exit') A FIELD 9N 0B 7 19 A CHECK(ER)
Code:ctl-opt option(*srcstmt:*nodebugio); dcl-f test93d workstn infds( infoDS ); dcl-ds infoDS; keyPressed char(1) pos(369); end-ds; * Function keys. dcl-c ENTER const(X'F1'); * Named indicators. dcl-s IndicatorPtr pointer inz(%addr(*in)); dcl-ds Inds based(IndicatorPtr); f3 ind pos(03); end-ds; dow f3 = *off; exfmt fmt1; if f3 = *on; iter; endif; if keyPressed = ENTER; dsply ('Enter was pressed'); endif; enddo; *inlr = *on; return;
-
Re: Enter VS CHECK(ER)
If the value is 'A' and CHECK(ER) results inbeing passed to the program, it implies that the field on the screen is only one character wide. In that case, there should be no way for the user to press -Enter- unless the user didn't type anything into the field. And in that case, there would be no change in the field that would be signaled.
Does the record have the CHANGE() keyword specified?Tom
There are only two hard things in Computer Science: cache invalidation, naming things and off-by-one errors.
Why is it that all of the instruments seeking intelligent life in the universe are pointed away from Earth?
Comment
Comment