Guys:

Heres what I do on OpenSuse 13.1 x64:

/*---------------------------------------------------------------*/
/* #!/usr/bin/rexx                                               */
/*   rexx                                                        */
/*   Name:       sysbkup                                       */
/*   Coampany:     IDF                                           */
/*   Created:      11/01/14 ( guess )                            */
/*   Parameters or Arguments:                                    */
/*                 ctlfle = ctlname and location                 */
/*---------------------------------------------------------------*/
trace i
arg subsys funcin
call dfdisp '/media/disk'
if result = 0 then do;
  say 'Sysbkup could not find usb external /media/disk '||date(u)' 'time()
  exit(99);
end;
say 'Sysbkup Found /media/disk/ at: 'date(u)' 'time()
myBackup = .filefunc~new
myBackup~funcs = "Backup"
exit
::class filefunc
::method funcs ftype
  expose backup_sys ifunc
  select
   when backup_sys = "TSS" & ifunc = "COPY" then do;
        tssin = '/z/zOS1.13/TSS'
        tssout = '/z/zOS1.13/TSS/GZIPBACK'
        call bkuptss tssin tssout trace
   end;
   when backup_sys = 'TSS' & ifunc = 'GZIP' then do;
        tssin = 'z/OS1.13/TSS/GZIPBACK/'
        call gziptss tssin trace
   end;
   when backup_sys = 'TSS' & ifunc = 'COPYEXT' then do;
        tssin = 'z/zOS1.13/TSS/GZIPBACK/'
        foldda = '';
        foldmo = '';
        foldyr = '';
        foldmo = substr(date(u),1,2);
        foldda = substr(date(u),4,2);
        foldyr = substr(date(u),7,2);
        bkupfold = 'B'||foldmo||foldda||foldyr
        tssout = '/media/disk/zpdt-backups/tss/'||bkupfold
        call copyext tssin tssout trace
  end;

All the calls are external rexx programs/scripts in the same folder.

HTH,

Regards,
Scott

On Tue, Mar 29, 2016 at 11:31 AM, Scott Ford <[email protected]> wrote:

> Guys,
>
> I try to write so i can pass multiple args. I have been doing some OOrexx
> and like it. Just the OO part of it is a tad of a learning curve for this
> T-rex ....
>
> Scott
>
> On Mon, Mar 28, 2016 at 11:31 PM, Paul Gilmartin <
> [email protected]> wrote:
>
>> On Tue, 29 Mar 2016 12:38:05 +1100, Wayne Bickerdike wrote:
>>
>> >I would use CALL. Implies that you want to return to the caller. Works in
>> >all environments.
>> >
>> And the search order is different in each.
>>
>> >Most of my REXX code can then be ported to REXX/CICS without major
>> >rewrites.
>> >
>> >Another plus of CALL is that the called routine can be internal or
>> external
>> >to the mainline code.
>> >
>> Internal gives you some funky variable scoping.
>>
>> And CALL lets you return arbitrary strings, not merely integers.
>>
>> -- gil
>>
>> ----------------------------------------------------------------------
>> For IBM-MAIN subscribe / signoff / archive access instructions,
>> send email to [email protected] with the message: INFO IBM-MAIN
>>
>
>

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [email protected] with the message: INFO IBM-MAIN

Reply via email to