Retro video games delivered to your door every month!
Click above to get retro games delivered to your door ever month!
X-Hacker.org- Force 4.0 Reference - prstatus() return printer port status http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
 prstatus()          Return printer port status
------------------------------------------------------------------------------
 Declaration
   printer.hdr

 Syntax
   func uint prstatus extern
   param value uint uLPTNumber

 Arguments
   uLPTNumber is the printer port to check.

 Return
   Printer status code as listed below.

   +--------------------------------------------------------+
   | Macro           |   Value        | Status              |
   |-----------------+----------------+---------------------|
   | PRN_NOERROR     |   0            | No error            |
   | PRN_OUTOFPAPER  |   1            | Out of paper        |
   | PRN_IOERROR     |   2            | General I/O fault   |
   | PRN_OFFLINE     |   3            | Printer is off-line |
   | PRN_BUSY        |   4            | Printer is busy     |
   +--------------------------------------------------------+

 Description
   This function returns the status of the specified printer port.

 Example
   #define EXAMPLE_IO
   #include example.hdr

   proc Test_prstatus
   vardef
      uint n
   enddef
   for n := 1 to 3
      ? "LPT" + istr( n ), "status is", istr( prstatus( n ) )
   next
   endproc

   proc main
   Test_prstatus()
   endproc

Online resources provided by: http://www.X-Hacker.org --- NG 2 HTML conversion by Dave Pearson