be sure you copy past the whole thing above. It compile ok to me. I did few minors change to the one you posted before.

I guess about a IF (condition a) AND (condition b) then... line... right?