The stdout environment has a default way of handling the output dataset from RXS: The dataset will be shown in an edit screen - presuming that the RXS program has written something into the dataset. If the dataset is empty, nothing will happen.
If general order outfunc is assigned a value, this default for 'termination action' in the stdout environment is overruled. Following options exists:
Outfunc='sub' prerequisites - for good results - that the RXS program has created JCL statements in the output dataset.
Outfunc='mqput' prerequsites that out is assigned the name af a MQSeries message queue residing on the queue manager which is defined as current for RXS. More information in Section 27.
Outfunc='nop' means that the RXS program just terminates after writing the dataset.
Outfunc=anything. Any TSO-command, CLIST / REXX may be used as outfunc. Such a command may use parameters. The command does not have to have any relationship to the output dataset. Example: outfunc='t' means that the actual time is written on the screen on the termination of the RXS program (t is a tso-command giving actual time). Observing the rules in Section 27, even a RXS program may be used as outfunc.
nbr = random()
'Square of' nbr 'is' nbr**2
In this example both out and outfunc are general orders to the action block. Therefore they are wirinten on separate lines, using the contination marker for general oders: ')&' Alternatively bot order may be written in the same line separated by ;. The execution of the RXS program results in the string ‘Square of 25 is 625' (presuming the random number happens to be 25) being written to the dataset 'myuser.myout' and this dataset is finally presented on screen using ISPF browse.