× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



Dennis,

No, you position the file pointer within the subprocedure. I read
somewhere, that each invocation has its own ODP, but i will not count on
that. May btrue, but i have not tested this, therefore I save the key
values and so a SETGT after the return.

I think in "simple" pseudo code:

callp pgmref(pgm)

eval keypgm = pgm
keypgm SETLL pgmrefpf
keypgm READE pgmrefpf
DOW <> EOF
|
eval keysave = keypgm
callp pgmref(calledpgm)
eval keypgm = keysave
key pgm SETGT pgmrefpf
keypgm READE pgmrefpf
ENDDO

return

key pgm and key save are local defined variables within the procedure.

In fact similar as writing a treeview sort of PGM.

With regards,
Carel Teijgeler


*********** REPLY SEPARATOR ***********

On 26-3-2010 at 11:19 Dennis Lovelady wrote:

you can use a recursively called subprocedure on the same *OUTFILE.

To add a key use ADDPFCST.

Before calling the subprocedure again, save the key values, after the
call
restore the key values and SETGT.

What if the DSPPGMREF pulls in values that are less than the current key
value? Won't I miss those?

List APIs require USRSPCes and you cannot use one, as the next time the
API
is called the USRSPC is cleared, IIRC.

Like IBM, I can do what I want if I own the code, right? One would just
need to keep track of where one was in the USRSPC... perhaps by storing
such
information within the USRSPC itself. (For example, the generic header
"Size of User Space" would provide a clue.

But I wasn't thinking of doing this recursively. I was thinking of
writing
an API to retrieve program refereneces... and then using THAT in my
recursive process.

Dennis Lovelady
http://www.linkedin.com/in/dennislovelady
--
"Don't knock the weather; nine tenths of the people couldn't start a
conversation if it didn't change once in a while."
-- Kin Hubbard



--
This is the Midrange Systems Technical Discussion (MIDRANGE-L) mailing
list
To post a message email: MIDRANGE-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/midrange-l
or email: MIDRANGE-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at http://archive.midrange.com/midrange-l.


Geen virus gevonden in het binnenkomende-bericht.
Gecontroleerd door AVG - www.avg.com
Versie: 9.0.733 / Virusdatabase: 271.1.1/2769 - datum van uitgifte:
03/25/10 08:33:00




As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.