how a varible can be passed to a subfile...accnt1 contain
data in a data area..ie Daccnt1 uds,Daccnt2 3
overlay(accnt1:1),
DNo 4 overlay(accnt1:4)..we want to transfer this dataarea
value from acnt0001 to a subfile..that means to enter each
record we have to incriment account no,,
i normal window we can do
move accnt1 account_no
eval account_no=accnt1
eval no=no+1
exfmt usr_account
how it possible with Subfile????????.Please do answer?
(Thank you for all your answers dear friends!!)



how a varible can be passed to a subfile...accnt1 contain data in a data area..ie Daccnt1 uds,D..

Answer / ajay

I didn`t get your question clearly but below my comments
help you....

As you want subfile to show incremented account number
and as stated in ur question you are fetching initial value
for account number from dataarea accnt1

do n ( n :- subfile page size)
move accnt1 account_no
eval account_no=accnt1
eval no=no+1
write sfl_format
eval rrn=rrn+1 ( rrn :- this is associated with SFL)
enddo
exfmt sfl_ctlfmt

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More IBM AS400 AllOther Interview Questions

what is qcmdexc?

1 Answers   IBM,


Suppose you have 3 members in a database file. How to read records from all the members Without using CL (OVRDBF) i.e. it should be handled exclusively in an RPG program?

6 Answers   IBM,


To Add A File To The 'file Selection' Option Of A Query, The Function Key To Be Pressed Is?

0 Answers   IBM,


what does check opcode is used?

1 Answers   IBM,


what is rpg ?

1 Answers   IBM,






Can level check error occur if we do chgpf?

0 Answers  


What is a library list ?

1 Answers  


a program variable coded in an embedded sql statement is referred to as?

1 Answers   IBM,


which cl command is used to trap error messages during program execution?

0 Answers   IBM,


why is as/400 called object oriented machine?

1 Answers   IBM,


what is the command used to invoke rlu ?

1 Answers   IBM,


when are the unique constraints executed?

0 Answers   IBM,


Categories