The PGMA calls PGMB.PGMB generates a report.The report
should contain the called program name(PGMA).How do i get
the called program name in PGMB to print it on the spool
file?(calling program name should NOT be hard coded or
passed as parameter to called program?
Answers were Sorted based on User's Feedback
Answer / harshad
Update LDA with PGMA & retrieve the same in PGMB for
printing.
Is This Answer Correct ? | 6 Yes | 0 No |
Answer / swetha p rao
There is an API QWVRCSTK to find out the called program name
If we pass required parameters to the API we can find out
called program name.
Is This Answer Correct ? | 4 Yes | 0 No |
Answer / ld123q44
Use a data area. Just before calling Pgm B stick Pgm A name
in the data area. Then when you are in Pgm B examine that
data area and get the value loaded in Pgm A.
Is This Answer Correct ? | 3 Yes | 1 No |
Answer / syam
For RPG program use this in PGMB to get program name and
move to Print
I SDS
I *Program PGM
For ILE RPG
D SDS
D PGM *PROC
YOu will get program name in PGM
Is This Answer Correct ? | 3 Yes | 3 No |
Answer / sreedhar reddy
Retrieve Call Stack (QWVRCSTK) API will do it.
Is This Answer Correct ? | 0 Yes | 0 No |
Answer / renjith
When you call pgm B send a parameter also which contains
the name pgm A. so in report for the name of pgm A you can
move the parameter value.
Is This Answer Correct ? | 3 Yes | 5 No |
What is the RPG cycle?
What is ment by record level identifier?
Delete FileName at first statement in RPG.
How to read a record from file where there is multiple record occurrence is available?
how do I declare a minor?
how does the rpg element work?
1) How to declare a file? 2) How to define a display file? 3) How to monitor error messages in RPG? 4) How to find the attributes for subfiles? and what is the DDS for subfiles?
i have 1000 records in pf.what are all the ways to read a particular name records in rpg?? ie.. in pf i have a name called demo appeared around 52 times hw will we read this particular records in rpg/400?.
Some times While checking MSGW for object / member / record locks ,I have seen it's locked by itself ...? How it happen and what action we need to perform if job is updating / writing a record....?
what is difference between DSPFD and DSPFFD?please give me real senario with good example?
please help me answer to this question what is the difference between the binding and srvpgm in ilerpg?
What is the purpose of Panel Groups?