SUBROUTINE ErrWrt ( ErrMsg ) c c-------------------------------- ErrWrt ------------------------------------- c c >>> ErrWrt -- writes a message to the standard error output file c c *** Calling Sequence: CALL ErrWrt ( ErrMsg ) c c === Latest Revision: 25 May 1988 (typed in) c c --- on entry the calling routine supplies -- c c ErrMsg -- CHARACTER string to be written to standard error c c --- on exit the routine returns -- c c nothing c c----------------------------- local declarations ----------------------------- c c CHARACTER*(*) ErrMsg c c * * * * * ! INTEGER globals CHARACTER*8 IGlobal c * * * * * ! output line CHARACTER*80 Line c * * * * * ! output format CHARACTER*8 MyForm c c * * * * * ! standard error unit number INTEGER StdErr c * * * * * ! right index function INTEGER IndexR c * * * * * ! # CHARACTERs to output INTEGER NCOut c c---------------------------- execution begins here --------------------------- c IF( IGlobal('get','StdErr',StdErr) .ne. 'OK' ) RETURN c Line = ErrMsg NCOut = max(1,IndexR(Line)) c MyForm = '(a!!)' WRITE( MyForm(3:4), '(i2)' ) NCOut c WRITE( StdErr, MyForm ) Line(1:NCOut) c RETURN end