Highlighted
Absent Member.
Absent Member.
970 views

[archive] Terminate ACCEPT from event procedure

[Migrated content. Thread originally posted on 22 March 2004]

Is it possible to cause an ACCEPT statement to terminate from within an event procedure? I tried setting ACCEPT-CONTROL to 1, 2, and 3 and none of them seem to have any effect.

I'm using an ActiveX control which "eats" all keyboard input, and I want to be able to allow the user to exit the program with the ESC key when the control has focus. I am determining ESC has been pressed in the event procedure, but then I don't know what to do after that to get the program to end the ACCEPT.
0 Likes
3 Replies
Highlighted
Absent Member.
Absent Member.

RE: [archive] Terminate ACCEPT from event procedure

Hint: Look up documentation on EVENT-ACTION.
0 Likes
Highlighted
Absent Member.
Absent Member.

RE: [archive] Terminate ACCEPT from event procedure

Ah, thanks.

I started looking at that, but saw the sentence at the beginning of its description that said "EVENT-STATUS is used to identify which data item is to receive information about screen events."

When I saw that it said it is used to "receive information", I stopped, not expecting that anything would happen if I moved values into it.
0 Likes
Highlighted
Absent Member.
Absent Member.

RE: [archive] Terminate ACCEPT from event procedure

Moving EVENT-ACTION-FAIL-TERMINATE to the EVENT-ACTION within your event procedure should terminate the control with a W-EVENT key status.
0 Likes
The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.