Sorry for the English, but this will be a long message.
If you are calling a 27x132 format pgm (even if defined with 24x80 as well), the caller's dspf must at least have the following specified:
Code:
DSPSIZ(24 80 *DS3
27 132 *DS4)
I have found that it is sometimes not the direct caller, but rather the next called pgm that will fail because of a format difference.
So this would look something like this:
Code:
pgma (24x80) calls pgmb (24x80) --> no problem
then pgma calls pgmc (both sizes) --> no problem
then pgma call pgmd (24x80) --> no problem
then pgma calls pgme (24x80) --> absturtz
then pgma calls pgmc --> no problem
then pgmc calls pgmb --> absturtz
** Why pgme crashes, but not pgmd, I don't know and didn't have the time (was not in the budget) to find out why.
To overcome this, and to avoid having to change many dspf's, you can do the following:
1. create a dummy dspf with both formats defined.
2. in your pgm, define your dspf and the dummy dspf, both as USROPEN.
3.
Code:
// open dummy size
open dum27x132;
write dummy1;
close dum27x132;
// open proper size
open in017gft;
.....
do whatever
.....
//EOJ
//set dummy size
close in017gft;
open dum27x132;
write dummy1;
close dum27x132;
Note: I used this technique to replace all the vendor's search pgms with our, without having to recompile or change any vendor pgms.
Bookmarks