Welcome Serena Central users! CLICK HERE
The migration of the Serena Central community is currently underway. Be sure to read THIS MESSAGE to get your new login set up to access your account.
barbmathews Absent Member.
Absent Member.
1038 views

COBOL question, accept/display

This is a how-to COBOL question.  We run acu-cobol with a customized runtime that includes a C routine for a custom form/screen handler.  We are in the process of converting our source code to use accepts & displays instead of our custom forms routines.

In our old routines, if you choose to edit an alphanumeric field, we display the current value of the field & let the user type over it.  To change a field with the value "WASHINGTON", you could type the word "ADAMS" & press enter and all characters after ADAMS were erased.    When we do the same action using accept/displays, the trailing letters are not erased when you press enter, and you are left with the value "ADAMSNGTON".  Is there any way around this, other than simply resetting the field to spaces before entry?

0 Likes
1 Reply
Micro Focus Expert
Micro Focus Expert

RE: COBOL question, accept/display

You can use the notify-change property of an entry field. Each time the person enters a character, you would have a notify-change event, you could count the numbers of entries thay make and they when the enter key is used (or whatever method they use to leave the field) you could use reference modification to ascertain their entry

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.