Well, I am embarrased to have this asked, but maybe my coffee is not strong enough.

Isn't these two totally equivalent?

Code:
IF w1>A THEN
    IF w1<B THEN
        DO SOMETHING
    ENDIF
ENDIF
Code:
 
IF w1>A AND w1<B THEN DO SOMETHING
They do not respond as expected. I mean as the second snipet.

Ioannis