During testing, you received comments that the default functionality of the [Commit] key can cause and error message to be displayed if there are no changes to save when it was activated. You decide to provide a button for users to validate the form and issue a commit if necessary. To implement this, you write a form-level procedure called VALIDATE_AND_COMMIT. The same functionality must be provided when the users chooses File > Save from the menu or presses the [Commit] key.
Which should you use?
A.
The When-Button-Pressed trigger with the code
DO_KEY(commit;);
A form-level Key-Commit trigger with the code
validate_and_commit
B.
The When-Button-Pressed trigger with the code.
DO_KEY(‘COMMIT_FORM’);
A form-level Key-Commit trigger with the code.
DO_KEY(‘COMMIT_FORM’);
validate_and_commit;
C.
The When-Button-Pressed trigger with the code
DO_KEY(‘[COMMIT]’);
A form-level Key-Commit trigger with the code
DO_KEY(‘validate_and_commit’);
D.
The When-Button-Pressed trigger with the code
DO_KEY(‘COMMIT_FORM’);
A form-level Key-Commit trigger with the code
validate_and_commit;
E.
The When-Button-Pressed trigger with the code
validate_and_commit;
A form-level Key-Commit trigger with the code
DO_KEY(‘COMMIT_FORM’);