Concerns When Using INH in Programs

The AcroBASIC inhibit command (INH) has some subtle nuances that must be known to properly use the command.

  1. INH can only be used with a single flag number or alias.

  2. INH cannot be used with boolean operators.

  3. INH can be placed on the same line with no delimiters in between. This

does not create an logical AND condition. It executes them in order from left to right, so the first condition must become true and then next INH is then evaluated. If you desire to check for multiple conditions to be true simultaneously, you must use an IF or WHILE statement.

EXAMPLES

Wait Until Active vs. Inactive:
INH 0 : REM wait until input 0 becomes active
INH -0 : REM wait until input 0 becomes inactive

 

This is not an AND condition:
INH 0 INH 1 INH 2 : REM Which is the same as three separate lines...
INH 0
INH 1
INH 2

To make an AND condition with IF:
IF (BIT0 AND BIT1 AND BIT2) THEN PRINT "ANDed good!"

 

Using an alias with INH example:
#DEFINE Moving BIT516 : REM assign an alias to bit 516
INH Moving
INH -Moving