Aleksandar Donev wrote:
>
> Hello,
> Assume I want to do the same WRITE statement to two units and want to avoid
> rewriting the same WRITE twice. For example, I want to both log things into
> a file and display them to the screen.
> Does anyone have a way of doing this other than calling WRITE from inside a
> loop which changes the UNIT number?
> Thanks,
> Aleksandar
Are you working under Unix? If so, look into the tee command. Something like
a.out | tee filename
I think should send "*" output of a.out to both the screen and file "filename".
Bill
--
William F. Mitchell
Mathematical and Computational Sciences Division
National Institute of Standards and Technology
[log in to unmask] http://math.nist.gov/~mitchell
|