Retro video games delivered to your door every month!
Click above to get retro games delivered to your door ever month!
X-Hacker.org- Novlib 3.30 Online Reference - <b> qjbflagget() / qjbflagset()</b> http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
 QJbFlagGet() / QJbFlagSet()
------------------------------------------------------------------------------
 Purpose:
 Get or set the status flags of a queue job.

 Syntax:
 iFlags = QJbFlagGet( dwQueueID, iJobNum )
 iFlags = QJbFlagSet( dwQueueID, iJobNum, iNewFlag )

 Parameters:
 dwQueueID The print queue ID number.
 IJobNum   The print job number.
 INewFlag  The job control flag mask.

 Returns:
 A numeric value (signed short int).

 The CA-Clipper names for these functions are:
 QJbFlgGet() / QJbFlgSet()

 Description:
 QJbFlagGet() returns the control flags for a print job specified by
 iJobNum in print queue dwQueueID. Returns NOVERRINT if an error occurs.

 QJbFlagSet() sets the print job control flags; iNewFlag is the
 flag mask which comprises the following bits:

 Bit   Value  Description
 3       8    Job will be serviced automatically if connection broken
 4      16    Job remains in queue after server aborts job
 5      32    Client has not filled associated job file
 6      64    User Hold - job advances, but cannot be serviced until hold
              is cleared by user or operator.
 7     128    Operator Hold - job advances, but cannot be serviced until
              hold is cleared by an operator.

 To change a flag, it must be read first by calling QJbFlagGet(),
 then OR'ed with the appropriate value and passed to QJbFlagSet() as
 NewFlag.

 Returns NOVERRINT if an error occurs.

 Example:
 //To set the operator hold flag of job 511 in print queue PRINTQ_0:
 dwCurrQ = QueIDGet( "PRINTQ_0" )
 if ( dwCurrQ != NOVERRLONG )
    iFlags = QJbFlagGet( dwCurrQ, 511 )
    if ( iFlags != NOVERRINT )
       if ( iFlags < 128 )
          iFlags = iFlags + 128   // Set Operator hold bit
       endif
       QJbFlagSet( dwCurrQ, 511, iFlags )
    endif
 endif

 Notes:
 WARNING: USE WITH CAUTION. Only use if you have a good knowledge of
 how the NetWare QMS works.

See Also: QJbOperatorHoldGet() / QJbOperatorHoldSet() QJbUserHoldGet() / QJbUserHoldSet()

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