|
I have never used ASSUME or KEEP before, or not that I can recall. So I am having some difficulties.
I have a display file that contains a window format that I want to use as a common dialog. I want to be able to call the program from other display programs, and have the common dialog display on top of the current screen without the display being blanked first. It seems to me that ASSUME would fit the bill. The documentation says:
Specify the ASSUME keyword for at least one record format within the display file so that the IBM i
operating system does not erase the display when the file is opened. In addition, specify the OVERLAY
keyword with the ASSUME keyword to prevent the IBM i operating system from deleting the display when
your program sends the first output operation after opening the file.
and
For the IBM i operating system to process the data correctly, your program must specify the record
format name containing this keyword.
Here is my assume record format.
A R ASSUME
A ASSUME
A OVERLAY
A 1 3' '
I am including it in the program, but I do not actually perform any I/O operations to it. The terminology of that second quote is a bit ambiguous as I am specifying it in the program on the INCLUDE keyword, but not in an I/O operation. Do I need to do an input or output to that record?
Another thing that would be throwing a wrench in the works is the DSPSIZ keyword since this common dialog should work with both *DS3 and *DS4 displays. I know that the screen is cleared when the display mode changes, but the ASSUME keyword should prevent that because:
A file with the ASSUME keyword will be opened to the display size of the file with the KEEP keyword.
Coincidently, the file currently on the screen displays only in *DS4 mode, and that file (different from the one contain the common dialog) has a record with the KEEP keyword on it, though once again I am not outputting the KEPFM record. Do I need to?
A R KEPFM
A KEEP
A OVERLAY
A ERASE(HDRCTL1 -
A )
So displayfile A (has KEEP record in it) is on the screen, I want to display a window from display file B (has ASSUME record in it). Display file A has DSPSIZ(*DS4), display file B has DSPSIZ(*DS3 *DS4). I am hoping for the window in display file B to overlay the screen from display file A in *DS4 mode, but instead when I display the window, the screen is cleared, and the window displays in *DS3 mode. Obviously I am missing something. Any ideas what that might be?
Mark Murphy
STAR BASE Consulting, Inc.
mmurphy@xxxxxxxxxxxxxxx
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.