Writing to log file using ExecWait
Hello
I am trying to use ExecWait to redirect java output (error and system.out) to a log file. Using the example given in other threads i came up with the sample below. But the log file is still empty infact the java program was not executed.
ExpandEnvStrings $0 %COMSPEC%
ExecWait '"$0" /C "$INSTDIR\JRE\Win32\bin\javaw.exe" -Djava.endorsed.dirs="$INSTDIR\Tomcat\common\endorsed" -cp Test "Hello World" > "$INSTDIR\installer.log"' $5
Note:
However trying this (without all the ExpandEnvStrings) execute the java program.
ExecWait '"$0" /C "$INSTDIR\JRE\Win32\bin\javaw.exe" -Djava.endorsed.dirs="$INSTDIR\Tomcat\common\endorsed" -cp Test "Hello World"' $5
I did not use nsExec because it does not work with the special build ( build that uses NSIS compiler maximum string length of 8192 bytes)