How load a subfile inquiry screen from arrays

5 pts.
Tags:
Arrays
RPG/400
Subfile
I need to display a subfile inquiry screen.But not directly from the file.I have to pass the records into arrays.From the array with specific conditions i need to load the subfile inquiry screen. How can i achieve this?

Answer Wiki

Thanks. We'll let you know when a new response is added.

Not much different from using a file
You step through the array
If the element qualifies to be added
You put the element into the subfile fields
add 1 to the SFL rrn
write the subfile record

Heres some sample code.

For X = 1 to MaxX
if Arr(X) = ”” your rules here
Eval SFLFLD1 = Arr(X)
Eval SFLRRN += 1
Write SFLRCD
endif
EndFor

Phil

Discuss This Question:  

 
There was an error processing your information. Please try again later.
Thanks. We'll let you know when a new response is added.
Send me notifications when members answer or reply to this question.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy

Forgot Password

No problem! Submit your e-mail address below. We'll send you an e-mail containing your password.

Your password has been sent to:

To follow this tag...

There was an error processing your information. Please try again later.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy

Thanks! We'll email you when relevant content is added and updated.

Following