Using Brian Leach's procwrite suggestion, I can do it if I write a basic wrapper around SETPTR that will pass the &HOLD& id back to the proc. User exit?: forgetaboutit.
So here's my original simple example > 01: EXECUTE \SETPTR 0,132,59,0,0,3,AS UNIQUE CDSTST,BRIEF\ CAPTURING SETPTR.OUTPUT > 02: HOLD.ID = SETPTR.OUTPUT<2> ; * Hold file "CDSTST_n" > 03: HOLD.ID = HOLD.ID[ \"\, 2, 1 ] ; * CDSTST_n > 04: EXECUTE \LIST VOC SAMPLE 2 LPTR\ > 05: EXECUTE \CT &HOLD& "\: HOLD.ID :\"\ rewritten below under the new scheme. The proc with the setptr command replaced by tstwrapper. (Line 7 retrieves what was written to the input buffer via procwrite in TSTWRAPPER.) 01 PQ 02 HRUN CDS.BP TSTWRAPPER 03 P 04 HLIST VOC SAMPLE 2 LPTR 05 P 06 HCT &HOLD& 07 A1 08 P where CDS.BP TSTWRAPPER is: 01 EXECUTE \SETPTR 0,132,51,0,0,3,AS UNIQUE CDSTST,BRIEF\ CAPTURING SETPTR.OUTPUT 02 HOLD.ID = SETPTR.OUTPUT<2> ; * Hold file "CDSTST_n" 03 HOLD.ID = HOLD.ID[ \"\, 2, 1 ] ; * CDSTST_n 04 IF SYSTEM(16) THEN PROCWRITE HOLD.ID ; * system(16) true iff called from a proc > If I were designing my current ap from scratch, I doubt I'd use this approach, but it does allow me to retrofit some mods with minimal rewrite & keeping consistency of style, which is good for long-term maintainability. I'll generalize the tstwrapper routine into a SETPTR.HOLDUNIQ verb, or some such. Thanks, Brian & Kevin. cds ------- u2-users mailing list u2-users@listserver.u2ug.org To unsubscribe please visit http://listserver.u2ug.org/