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> capsetupstringget() / capsetupstringset()</b> http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
 CapSetupStringGet() / CapSetupStringSet()
------------------------------------------------------------------------------
 Purpose:
 Get or set the capture setup string.

 Syntax:
 lpszStr = CapSetupStringGet( iLPTNum )
 lpszStr = CapSetupStringSet( iLPTNum, lpszNewStr )

 Parameters:
 iLPTNum    The LPT device. 1=LPT1: 2=LPT2: 3=LPT3:
 lpszNewStr The new setup string.

 Returns:
 A character string of length 64.

 The CA-Clipper names for these functions are:
 CapSetStrGet() / CapSetStrSet()

 Description:
 CapSetupStringGet() returns the setup string for the specified LPT
 device iLPTNum. The setup string is a series of control characters sent
 to the printer before each print job from the calling workstation.

 CapSetupStringSet() sets the setup string for the specified LPT device
 iLPTNum to the specified value lpszNewStr and returns the previous setup
 string.

 Both functions return an empty string if an error occurs. The length of the
 setup string is controlled by the workstation shell and defaults to a
 maximum of 64 characters in length. To increase the allowed length of the
 setup string, include the line:

 PRINT HEADER=<length>
 in the workstation's SHELL.CFG file.

 The printer setup string normally consists of a series of escape codes to
 be sent to the printer, to change the printer settings.

 Example:
 // To setup an EPSON FX/LQ compatible printer to print 12
 // pitch, double width characters on the captured LPT1:
 lpszSetupString = chr(27)+"M"+chr(27)+"W"
 CapSetupStringSet( 1, lpszSetupString )
 if( NWErrorGet() = 0 )
    ? "The EPSON compatible printer being captured to by "
    ? "LPT1: is now printing 12 pitch double width characters"
 endif

See Also: CapResetStringGet() / CapResetStringSet()

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