|
Hi Scott,code
That was my first inclination as well. When using the debugger the
problem will not occur though? As soon as a turn the debugger off and
run the program again is crashes with the CPF5192...
Also, seen as though the a program will work if I Read (ExFmt) the
program 1 DDS file before reading (ExFmt'ing) the Program 2 DDS I'm
assuming the DDS is correct. The error only will occur when the RPG
reads the Program 2 Window DDS before a read to the Program 1 DDS. Iprogram.
have no idea why running the debugger would cause the error not to
occur. The only thing I can think of is that when the debugger displays
a Window in a separate DDS it never overlays the window over the
previous Display file, but rather completely clears the screen, then
showing just the window. When the debugger is not running though the
Window will be super-imposed over the previously displayed display file
(which seems to be causing the issue) As to why this is causing a
failure I haven't been able to figure out yet?
-----Original Message-----
From: rpg400-l-bounces@xxxxxxxxxxxx
[mailto:rpg400-l-bounces@xxxxxxxxxxxx] On Behalf Of Scott Klement
Sent: Saturday, 18 July 2009 12:20 AM
To: RPG programming on the IBM i / System i
Subject: Re: CPF5192 error message with RPG program.
Hi Steven,
This error usually occurs when you send "unprintable" characters to a
display file. If a character that you write to the screen gets
interpreted as a 5250 command (and one that's not structured properly)
the device gets confused and sends back a negative response code. The
OS gets the response code and sends the *ESCAPE message to your
Then,
I would recommend putting all of the DDS back the way you had it.
50
use the debugger to stop the program at the time that you are writing
data to the display. Examine the data and see which fields have the
unprintable ("garbage") characters in them, and then trace the problem
backward from that point.
Steven Harrison wrote:
Hi All,program
I have been receiving the following error in the job log when my
runs:
Message ID . . . . . . : CPF5192 Severity . . . . . . . :
Negative
Message type . . . . . : Escape
Date sent . . . . . . : 17/07/09 Time sent . . . . . . :
10:50:57
Message . . . . : Data sent to device AFXIT02A not valid.
informationresponsedata
code is 10050112.
Cause . . . . . : The condition was caused by the program output
containing below hex 40 or too many input fields. More
on99
theFormats
negative response code can be found in either the IBM 5494 Remote
Control
Unit Functions Reference (under negative responses) or the SNA
may
Manual (under SENSE or LUSTAT codes). Invalid data (below hex 40)
have
occurred in one of the following ways:
etc etc...
followed by:
Message ID . . . . . . : RNX1251 Severity . . . . . . . :
price
Message type . . . . . : Escape
Date sent . . . . . . : 17/07/09 Time sent . . . . . . :
10:50:57
Message . . . . : Permanent I/O error occurred in file STATUSD.
Etc etc...
The following is happening:
Program 1 displays a subfile containing the discount rates for a
Couldcode. The DDS for this program contains the subfile.
Program 2 is a service program that is responsible for displaying a
window that reports any status events that might take place (ie.
withnot find price code, discount rate invalid etc...). The DDS for the
window is in a separate display file. I have never had a problem
Window.this program and it is used by a number of other programs to display
status events.
The error is occurring when Program 2 is called to display the
singleWhile trying to figure out what was causing the error I started
stripping out code bit by bit to identify where the problem was
occurring. I ended up removing the subfiles from Program 1's DDS
altogether and ended up with just a Header record displaying a
calledtext field and a Footer record that contains indicators for the F12and
F03 keys. It seems that the error is occurring when 'ExFmt' is
inProgram
Program 2 before a read or ExFmt in Program 1.exists.
So with the following code the error would occur:
Program 1:
Write Header;
DoesPriceCodeExist() <- Procedure to determine if the price code
If it doesn't it sets a status event that can be displayed by
2.happening?
event.
Call Program 2 <- Calls ExFmt on the Window to display the status
The program will fall over at this point.
ExFmt Footer;
But with the following code the error won't occur:
Write Header;
ExFmt Footer;
DoesPriceCodeExist()
Call Program 2 <- Display the window reporting that the Price Code
doesn't exist.
ExFmt Footer;
I'm wondering if anyone can shed some light on why this is
DDSWhy will the ExFmt on the Window cause the program to crash if the
theit is overlaying has only had Writes to it but it will be fine if
listthere has been a previous Read/ExFmt.
Both DDS files are compiled with RSTDSP *YES. Also for some strange
reason the error will not occur if I'm running the program in the
Debugger?!?!? Which I find very strange.
Any help would be greatly appreciated.
Steve
--
This is the RPG programming on the IBM i / System i (RPG400-L) mailing
list
To post a message email: RPG400-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/rpg400-l
or email: RPG400-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at http://archive.midrange.com/rpg400-l.
--
This is the RPG programming on the IBM i / System i (RPG400-L) mailing
To post a message email: RPG400-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/rpg400-l
or email: RPG400-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at http://archive.midrange.com/rpg400-l.
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.