For IF you have to use ==. = is for assignment, and == will check if the given two parameters are equal. IF PTWOHIT==TRUE THEN 'code here. Also, consider using multi-line IFs: IF PTWOHIT==TRUE THEN 'code here 'more code here 'etc. ENDIF Also, PRINT "TEXT ":VARIABLE is invalid syntax. Replace the : with a ;.