how can i retrieve the field name from display file at run
time?
Devendra Singh Tomar

Answers were Sorted based on User's Feedback



how can i retrieve the field name from display file at run time? Devendra Singh Tomar ..

Answer / srikanth

If we use following RTNCSRLOC keyword in display with fields as specified, and if we place cursor on any field, CFLD will populate with field name.
A RTNCSRLOC(*RECNAME &CREC &CFLD &CPOS)
A CFLD 10A H
A CREC 10A H
A CPOS 4S 0H

Is This Answer Correct ?    2 Yes 0 No

how can i retrieve the field name from display file at run time? Devendra Singh Tomar ..

Answer / bindu

It is not possible to see field name at runtime

Is This Answer Correct ?    1 Yes 0 No

how can i retrieve the field name from display file at run time? Devendra Singh Tomar ..

Answer / guest

when you will get ans than plz tell us.......... anurag

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More RPG400 Interview Questions

i have a file with the values 10, 20, 30, 40, if am setll with the value 25 then readp, so what it will return?

6 Answers   Mind Tree,


Mr.Sidc sirfor my question{how to convert date format from one format to another i think in CL/400 its CVTDAT,Please tell in RPG/400 sir not in RPGILE} you have answered using MOVE opcode,can you illustrate me with a small example sir very kind of you.

1 Answers   CTS, IBM, iGate,


Difference between RESET and CLEAR

1 Answers   TCS,


Can any body give the code for this quesition? Using the following details write C-Spec code to set Name to"AMMU LABS SYSTEM" D NAME1 S 10 INZ('AMMU') D NAME2 S 10 INZ('LABS') D NAME3 S 10 INZ('SYSTEM') D NAME S 20

5 Answers  


If there are 1000 member(PGM type) in a SRC file. How can we compile in a CL program? ( It need to be done in a loop)?

1 Answers  






Can AnyOne tell me how to read join logical file in rpg from starting to end?

2 Answers  


what is mean by *MAP and *DROP?what commands use these two keywords?why are they used?

4 Answers  


what do you mean by an input subfile, what are the keywords required?

0 Answers   IBM,


Q:HI friends accually ihave one problem plesase let me know the alternate code of this code. Related field description of code: Add a field, CALvsPRD, "Calendar Day Starts Before/After Production Day" to the parameter set WRKORDER which accepts values 'A' or 'B' o B = Calendar Day Starts Before Production Day o A = Calendar Day Starts After Production Day o Any other value indicates the production and calendar dates are always the same. code: Automatic Execution Of *INZSR Subroutine /Z01 * retrieves WRKORDER field values. /Z01 * Calculate default Production Date and return it to caller. /Z01 * Production date defaults to system date /Z01 C Eval P@Pdate = %DATE() /Z01 * unless Calendar date starts Before PDN(production) date and /Z01 * system time is before PDN Start Time then /Z01 * PDN date is yesterday. /Z01 C If W@CALvsPRD = 'B' and /Z01 C %TIME() < %TIME (W@Strtime) /Z01 C Eval P@Pdate -= %Day(1) /Z01 * unless Calendar date starts After PDN date and /Z01 * system time is *GE PDN(production) Start Time then /Z01 * PDN date is tomorrow. /Z01 C ElseIf W@CALvsPRD = 'A' and W@Strtime > *Zero and /Z01 C %TIME() >= %TIME (W@STrtime) /Z01 C Eval P@Pdate += %Day(1) /Z01 C EndIf /Z01 C Eval *InLr = *On

0 Answers   IBM,


What is the compilation option that has to he specified while compiling an RPC program which uses a file having date data type field?

3 Answers   HSBC, IBM,


Suppose my file has 10 fields and I want to make the 2nd field zeros in all records. And assume I have millions of records and I dont want to read each record and update the desired field with 0. Any other way to do this in one step operation?

1 Answers  


1. If my rpg program has a date field, What extra care I have to take while compiling that RPG program? 2. If the file is keyed and I have declared the file as well as Key list properly in my program. Still am getting an error message like "Chain/reade operation is not allowed" What may be the case?

6 Answers   Virtusa,


Categories