[<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
 INWORD()
 Reads in a 16-bit word from a port
------------------------------------------------------------------------------
 Syntax

     INWORD(<nPort|cHexPort>) --> nWord

 Argument

     <nPort|cHexPort>  Designates a port address from which a word with a
     16-bit value is read.  This value can be a decimal integer or
     hexadecimal string.

 Returns

     INWORD() returns the word read from the designated port, or a value of -
     1 when an error occurs.

 Description

     CA-Clipper Tools always attempts to offer finished solutions at the
     highest-possible level for such standard hardware as a serial interface
     port.  However, if you read highly specialized systems and their ports
     from CA-Clipper, use INBYTE() or INWORD().  INWORD() allows you to read
     from interfaces that return the data from a port as a 16-bit value.

 Note

     .  A returns random value for a nonexistent port or one that
        cannot be read.

 Examples

     Show a read from a 16-bit port:

     .  With a decimal parameter:

        ? INWORD(512)           // Read from an additional device

     .  With a hexadecimal parameter:

        ? INWORD("200")         // The same port address


See Also: INBYTE() OUTWORD() NUMHIGH() NUMLOW()
This page created by ng2html v1.05, the Norton guide to HTML conversion utility. Written by Dave Pearson