i have written a small function for my setup that constantly checks for a failure in a log file a started program gives out
the error line i am looking for looks like this (it always ends with 'i_am_the_federation' <- that is important) and is one of many lines the program attaches to that log:
[ Warning::ST3D_GraphicsEngine:: 118@ 8699] Storm3D Warning: Sprites\gui_federation.spr: Couldn't find particle sprite node definition 'i_am_the_federation'
so here is the function i included in my setup script
FileOpen $0 "log.txt" "r"
FileRead $0 $2
StrLen $R0 $2
IntOp $R1 $R0 - 23
StrCpy $2 $2 1000 $R1
StrCmp $2 "'i_am_the_federation'$\r$\n" 0 loop
MessageBox MB_OK "error message placeholder"
;Clear the log
FileOpen $R3 "log.txt" "w"
Ok, the problem is not with the function itself,
but with the fileopen command.
the program cannot write to the file
during the reading time of my setup,
so the error cannot appear in the log.
so do you have a suggestion what i could change that the setup
doesn't block the program to write to the log file?