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.
JimRead Absent Member.
Absent Member.
1194 views

Character menu to graphical window

Jump to solution

Good Afternoon,

We have a character-based menu system that is launching a graphical program via CALL.  This creates a new window with the graphical screen in it.  When I exit this program though, the menu appears in the new window rather than that window closing and returning to the original window (which is still up in the background).  I don't know what I'm doing wrong or what I need to do differently in this case so that my menu continues to operate normally.

Currently, I am just calling DESTROY ALL CONTROLS and making sure to close all my files.

Thanks for any advice,

Jim

Tags (2)
0 Likes
1 Solution

Accepted Solutions
Micro Focus Expert
Micro Focus Expert

RE: Character menu to graphical window

Jump to solution

There are a few things going on here. I take it that the character-based menu system is a COBOL program run through AcuGT and run on Windows. If that is correct, the first time that a display statement occurs the AcuGT runtime creates a Window for your program. Then you do a call, does the called program display a Standard window, Floating window or Independent Window and at the end where you destroy all controls, do you close the Window handle

 DISPLAY Floating WINDOW, SIZE 29, LINES 12,

              TITLE "Calculator", BACKGROUND-LOW,

              HANDLE IN MAIN-WINDOW.

display screen

accept screen

destroy all controls

close window MAIN-WINDOW.

It would be good to put a display window statement in the character-based menu system so that you can establish the handle of that window. From that point forward, your called programs call destroy their controls and close their window handles.

View solution in original post

0 Likes
2 Replies
Micro Focus Expert
Micro Focus Expert

RE: Character menu to graphical window

Jump to solution

There are a few things going on here. I take it that the character-based menu system is a COBOL program run through AcuGT and run on Windows. If that is correct, the first time that a display statement occurs the AcuGT runtime creates a Window for your program. Then you do a call, does the called program display a Standard window, Floating window or Independent Window and at the end where you destroy all controls, do you close the Window handle

 DISPLAY Floating WINDOW, SIZE 29, LINES 12,

              TITLE "Calculator", BACKGROUND-LOW,

              HANDLE IN MAIN-WINDOW.

display screen

accept screen

destroy all controls

close window MAIN-WINDOW.

It would be good to put a display window statement in the character-based menu system so that you can establish the handle of that window. From that point forward, your called programs call destroy their controls and close their window handles.

View solution in original post

0 Likes
JimRead Absent Member.
Absent Member.

RE: Character menu to graphical window

Jump to solution

It appears that I was inadvertently skipping the close window and destroy all commands with a misplaced go-back.  I believe I have this situation in hand now, thank you for your time.

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.