Tatsukinさんの説明で、 B=button(2) If (B==16)==16 then A=A+1 は間違っていますね。これは、 B=button(2) If (B AND 16)==16 then A=A+1 が正しいです。 あと、 If B==16 then A=A+1 は正しいです。