I would like to print data displayed by a map. Is there a way to code printing with input using map and PF key together ?
You can see on the picture, I used pf1 for returning menu and pf4 for store data. If I would like to use pf7 for print, how can I code this ?
A code sample, an example is appreciated.
Thanks and regards.
I am not sure I understand your problem. It seems quite straightforward:
SET KEY PF7
INPUT your screen
IF PF-KEY = ‘PF7’
WRITE … stuff from map … / OR PRINT OR WRITE USING MAP
If this is not what you want to do, please expand your description.
Thanks for reply. I didn’t know the statement : “write using map”. It is quite helpfull.
I tried it and I have an error :
NAT0224 Input map in WRITE or write map in INPUT statement.
*** Explanation ***
Either you have specified in a WRITE USING MAP statement the name of a
map which is an input map, not an output map; or you have specified in
an INPUT USING MAP statement the name of a map which is an output map,
not an input map.
Whether a map is an input or output (write) map is indicated in its
How will I set this map as an output map in map settings ? Is it related with print mode ? Please see 2 images I attached.
Thanks and regards,
I have not had time to get back to this.
In case you have not resolved your questions as yet:
The error message tells you all you need to know.
“Whether a map is an input or output (write) map is indicated in its
If you look at the top right of a map settings you will see two entries: INPUT and WRITE
INPUT means “input” and WRITE means “output”.
A map can only be one. Thus, in your case you need two “versions” of the map, one input, one output.
If you have the map as input, you can save it under a new name, then edit the map. Go to map settings and change the X from INPUT to WRITE. Now stow the “write map”.
You should be able to take it from there.
Almost forgot, PM (print mode) has no bearing on this at all.
When you refer to “printing”, are you talking about a hardcopy (i.e. a screen print) ?
This can be done with terminal command %H, or “SET CONTROL H” from a program,
which you can, of course, assign to a PF key.