if not defined JobMgr_EchoLog_DPNE set JobMgr_EchoLog_DPNE=%~dp0zzTracActionInfo_log.txt
setlocal
 rem - Create TextToEcho
 set TextToEcho=%~1
 if "%TextToEcho%" equ ""  set TextToEcho=.
 if "%TextToEcho%" neq "." set TextToEcho=.%TextToEcho%

 if /I "%~3" equ ""  Echo%TextToEcho%
 if "%TextToEcho%" equ "." goto :EchoEnd
 if /I "%JobMgr_EchoLog_DPNE%" equ "." goto :Next
 Echo %date:~0,10% %time:~0,8% %TextToEcho:~1% >>"%JobMgr_EchoLog_DPNE%"
 :Next
 rem - Output in additional file
 if "%~2" equ "" goto :EchoEnd
 Echo%TextToEcho% >>"%~2"
:EchoEnd
endlocal

