In SX Microcontrollers, SX/B Compiler and SX-Key Tool, edgellmh wrote: Paul I thought you could use a variable as a bitIndex as: state byte tmp1 byte FUNCTION_CALL state FOR bitIndex = 0 TO 2 tmp1 = state.bitIndex IF tmp1 = 1 THEN CLOSE_DOME NEXT ---------- End of Message ---------- You can view the post on-line at: http://forums.parallax.com/forums/default.aspx?f=7&p=1&m=268167#m268269 Need assistance? Send an email to the Forum Administrator at forumadmin@parallax.com The Parallax Forums are powered by dotNetBB Forums, copyright 2002-2008 (http://www.dotNetBB.com)