Hi.

The following makes me mad:
Using OR to check for "0" or "-1" does not work, if the result is "-1".

So, if the file "%appdata%\PATH\file1.rtf" is newer than file @LDrive +"\resources\file1.rtf", the Result is "-1" but for KIX it does not matter and it goes into the THEN tree. But if the result was "1", it works as it should.

 Code:
$RESULT = COMPAREFILETIMES (@LDrive +"\resources\file1.rtf","%appdata%\PATH\file1.rtf")
MESSAGEBOX ("Result=: $RESULT", "Box", 4160)
	IF $RESULT = "0" OR $RESULT = "-1"
		MESSAGEBOX ("Now we are at THEN", "Box", 4160)
	ELSE GOTO SKIP	 
	ENDIF
goto END

:SKIP
MESSAGEBOX ("Now we are at ELSE", "Box", 4160)

:END
exit


Edited by lho (2008-07-15 11:17 AM)