Hello all,

Just to keep things simple and not going into alot of details here is my question:

Can you use a variable in the port settings?

Example....

main:
for I = 0 to 7
if portb.I = 1 then xxxxx
next I
goto main

If so how do you setup the variable? (I var byte)

I have tired and tried and it always says:
"ERROR Line X: Bad variable modifier: .I."

What I am trying to do is scan a port for changes with out using 8 seperate If...then lines.

Any help is always appreciated.

Thanks,
Bill12780

SETUP:
16f873
easypic4 dev board
picbasic pro v2.47
using PM as compiler