please guys help me,I need to write a program that shows more
than one way to display a subfile. Both views are of the same
file but sorted differently and show different fields of the
same file when the user presses a function key. send me code
Answers were Sorted based on User's Feedback
Answer / guset
You can create two subfile record format.
When press function key then it will show second subfile
record with different fields. but records showing different
manner i mean suppose the file has 15 records. Subfile size
is 5 then first time it will show first 5 if we press
function key then it will show next 5 records with
different field name.
Is This Answer Correct ? | 3 Yes | 0 No |
Answer / venkat
by multi-memeber concept we can write as per your requirements
Is This Answer Correct ? | 2 Yes | 0 No |
Answer / chandrababu
This Case we can do by using Subfile fold/drop option. for Example F11 function key for Fold/Drop in subfile. see the code below.
FDSPLYFILE CF E WORKSTN SFILE(SFLREC1:@RRN1)
SFILE(SFLREC2:@RRN2)
FDBFILE IF E K DISK
D @RRN1 S 5 0 INZ(0)
D @RRN2 S 5 0 INZ(0)
C EXSR LOAD
C WRITE FOOTER
C DOW *IN03 = *OFF
C 03 LEAVE
C EXFMT CTLREC1
C IF *IN11 = *ON
C EXFMT CTLREC2
C ENDIF
C ENDDO
C EVAL *INLR = *ON
C LOAD BEGSR
C Read DBFILE
C DOW Not %EOF
C EVAL @RRN1 = @RRN1 +1
C EVAL @RRN2 = @RRN2 +1
C WRITE SFLREC1
C WRITE SFLREC2
C Read DBFILE
C ENDDO
C IF @RRN1 > 0 and @RRN2 > 0
C SETON 3031
C ENDIF
C ENDSR
Is This Answer Correct ? | 1 Yes | 0 No |
What is file identifier where we can use?
Difference between creating a report using Printer file and WRKQRY(Query Report) ?
1.How can you search an entire source file for a particular field name? 2.How can you find the differences between two versions of the source for the same program? 3.What is a hidden field as it relates to a sub file? 4.How do you display a sub file that has no records in the sub file?
3 members in a databasefile .how to read records from all the members?????????
what is *place and *auto keyword in prtf ?plz explain
What is the RPG cycle?
1) How to define keyed file in CL pgm. 2) How can i read particular records in CL pgm from database file.
Hi, Can anybody give me real sinario for SFLRCDNBR?with example?
1. Which Built-In-Function will you use to achieve the following functionality? CLONO1NO2NO3 Factorl÷÷+OpcdeFactor2++÷ResultLenDHHiLoEq C QTY IFLT *ZERO C QTY MULT -1 QTY C ENDIF a) %ABS b) %TRIM c) %TRIMS d) %UNS
Can anybody tell me in which scenario we have to use SQLRPG .(Embeded SQL)....?
Anybody can explain the difference between SFLCLR & SFLINZ?
Hi, can any one tell me :IN CASE OF SINGLE PAGE FILE HOW WILL I LOAD THE PREVIOUS PAGE WITHOUT THE USE OF SFLCLR INDICATOR ?