369 lines
9.6 KiB
HTML
369 lines
9.6 KiB
HTML
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
|
<html>
|
|
<head>
|
|
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
|
|
<meta name="Copyright" content="Copyright (c) 2006 by IBM Corporation">
|
|
<title>Build Open Time Commands (QSPBOPNC) API</title>
|
|
<!-- Begin Header Records ========================================== -->
|
|
<!-- All rights reserved. Licensed Materials Property of IBM -->
|
|
<!-- US Government Users Restricted Rights -->
|
|
<!-- Use, duplication or disclosure restricted by -->
|
|
<!-- GSA ADP Schedule Contract with IBM Corp. -->
|
|
<!-- Print SCRIPT A converted by B2H R4.1 (346) (CMS) by V2KEA304 -->
|
|
<!-- at RCHVMW2 on 17 Feb 1999 at 11:05:09 -->
|
|
<!-- Change History: -->
|
|
<!-- YYMMDD USERID Change description -->
|
|
<!--File Edited by Kersten Oct 2001 -->
|
|
<!--End Header Records -->
|
|
<link rel="stylesheet" type="text/css" href="../rzahg/ic.css">
|
|
</head>
|
|
<body>
|
|
<a name="Top_Of_Page"></a>
|
|
<!-- Java sync-link -->
|
|
<script language="Javascript" src="../rzahg/synch.js" type="text/javascript">
|
|
</script>
|
|
|
|
<h2>Build Open Time Commands (QSPBOPNC) API</h2>
|
|
|
|
<div class="box" style="width: 70%;">
|
|
<br>
|
|
Required Parameter Group:<br>
|
|
<!-- iddvc RMBR -->
|
|
<br>
|
|
<table width="100%">
|
|
<tr>
|
|
<td align="center" valign="top" width="10%">1</td>
|
|
<td align="left" valign="top" width="50%">Receiver variable</td>
|
|
<td align="left" valign="top" width="20%">Output</td>
|
|
<td align="left" valign="top" width="20%">Char(*)</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<td align="center" valign="top">2</td>
|
|
<td align="left" valign="top">Length of receiver variable</td>
|
|
<td align="left" valign="top">Input</td>
|
|
<td align="left" valign="top">Binary(4)</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<td align="center" valign="top">3</td>
|
|
<td align="left" valign="top">Format name</td>
|
|
<td align="left" valign="top">Input</td>
|
|
<td align="left" valign="top">Char(8)</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<td align="center" valign="top">4</td>
|
|
<td align="left" valign="top">Printer device name</td>
|
|
<td align="left" valign="top">Input</td>
|
|
<td align="left" valign="top">Char(10)</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<td align="center" valign="top">5</td>
|
|
<td align="left" valign="top">Printer data stream type</td>
|
|
<td align="left" valign="top">Input</td>
|
|
<td align="left" valign="top">Char(10)</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<td align="center" valign="top">6</td>
|
|
<td align="left" valign="top">Spooled file attributes</td>
|
|
<td align="left" valign="top">Input</td>
|
|
<td align="left" valign="top">Char(*)</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<td align="center" valign="top">7</td>
|
|
<td align="left" valign="top">Error code</td>
|
|
<td align="left" valign="top">I/O</td>
|
|
<td align="left" valign="top">Char(*)</td>
|
|
</tr>
|
|
</table>
|
|
|
|
<br>
|
|
Default Public Authority: *USE<br>
|
|
<!-- iddvc RMBR -->
|
|
<br>
|
|
Threadsafe: No<br>
|
|
<!-- iddvc RMBR -->
|
|
<br>
|
|
</div>
|
|
|
|
<p>The Build Open Time Commands (QSPBOPNC) API uses the attributes of the
|
|
spooled file to build commands that must be sent ahead of the data to prepare
|
|
the printer to print the spooled file. These commands are referred to as
|
|
<em>open time</em> commands. The open time commands contain most of the file
|
|
level commands needed to format the printed output.</p>
|
|
|
|
<br>
|
|
|
|
|
|
<h3>Authorities and Locks</h3>
|
|
|
|
<p>The user must have *USE authority to the printer device description.</p>
|
|
|
|
<br>
|
|
|
|
|
|
<h3>Required Parameter Group</h3>
|
|
|
|
<dl>
|
|
<dt><strong>Receiver variable</strong></dt>
|
|
|
|
<dd>OUTPUT; CHAR(*)
|
|
|
|
<p>The receiver variable receives the information requested. When the size of
|
|
the area is smaller than the format requested, the API returns only the data
|
|
the area can hold. If the size of the area is greater than the format, the area
|
|
past the format is undefined.</p>
|
|
</dd>
|
|
|
|
<dt><strong>Length of receiver variable</strong></dt>
|
|
|
|
<dd>INPUT;BINARY(4)
|
|
|
|
<p>The length of the receiver variable. The amount of data is truncated if the
|
|
receiver variable is too small. Anything less than 8 bytes is not valid.</p>
|
|
</dd>
|
|
|
|
<dt><strong>Format name</strong></dt>
|
|
|
|
<dd>INPUT; CHAR(8)
|
|
|
|
<p>The format of the information returned in the receiver variable.</p>
|
|
|
|
<p>The valid format name is:</p>
|
|
|
|
<table cellpadding="5">
|
|
<!-- cols="25 75" -->
|
|
<tr>
|
|
<td valign="top"><em><a href="#HDROPNC100">OPNC0100</a></em></td>
|
|
<td valign="top">The open time commands for the spooled file.</td>
|
|
</tr>
|
|
</table>
|
|
|
|
<br>
|
|
</dd>
|
|
|
|
<dt><strong>Printer device name</strong></dt>
|
|
|
|
<dd>INPUT; CHAR(10)
|
|
|
|
<p>The name of the printer device description of the writer that was
|
|
started.</p>
|
|
|
|
<p>The following special value is allowed:</p>
|
|
|
|
<table cellpadding="5">
|
|
<!-- cols="10 90" -->
|
|
<tr>
|
|
<td width="15%" valign="top"><em>*NONE</em></td>
|
|
<td width="85%" valign="top">The printer device is unknown.</td>
|
|
</tr>
|
|
</table>
|
|
|
|
<br>
|
|
</dd>
|
|
|
|
<dt><strong>Print data stream type</strong></dt>
|
|
|
|
<dd>INPUT; CHAR(10)
|
|
|
|
<p>The type of data stream recognized by the printer writer. This is used to
|
|
determine the type of data to generate for open time command.</p>
|
|
|
|
<p>The valid special value is:</p>
|
|
|
|
<table cellpadding="5">
|
|
<!-- cols="10 90" -->
|
|
<tr>
|
|
<td valign="top"><em>*SCS</em></td>
|
|
<td valign="top">Systems Network Architecture (SNA) character string. A full
|
|
set of SCS commands (similar to the set sent to a 3812 printer) is
|
|
generated.</td>
|
|
</tr>
|
|
</table>
|
|
|
|
<br>
|
|
</dd>
|
|
|
|
<dt><strong>Spooled file attributes</strong></dt>
|
|
|
|
<dd>INPUT; CHAR(*)
|
|
|
|
<p>The attributes of the spooled file to be printed. These attributes are
|
|
obtained by using the Retrieve Spooled File Attributes (QUSRSPLA) API,
|
|
specifying format SPLA0200.</p>
|
|
</dd>
|
|
|
|
<dt><strong>Error code</strong></dt>
|
|
|
|
<dd>I/O; CHAR(*)
|
|
|
|
<p>The structure in which to return error information. For the format of the
|
|
structure, see <a href="../apiref/error.htm#hdrerrcod">Error Code Parameter</a>.</p>
|
|
</dd>
|
|
</dl>
|
|
|
|
<br>
|
|
|
|
|
|
<h3><a name="HDROPNC100">OPNC0100 Format</a></h3>
|
|
|
|
<p>The following table shows the information returned for the OPNC0100 format.
|
|
For more details about the fields in the following table see, <a href=
|
|
"#HDRFIELDC">Field Descriptions</a>.</p>
|
|
|
|
<table border>
|
|
<tr>
|
|
<th align="center" valign="bottom" colspan="2">Offset</th>
|
|
<th align="left" valign="bottom" rowspan="2">Type</th>
|
|
<th align="left" valign="bottom" rowspan="2">Field</th>
|
|
</tr>
|
|
|
|
<tr>
|
|
<th align="center" valign="bottom">Dec</th>
|
|
<th align="center" valign="bottom">Hex</th>
|
|
</tr>
|
|
|
|
<tr>
|
|
<td align="center" valign="top" width="10%">0</td>
|
|
<td align="center" valign="top" width="10%">0</td>
|
|
<td align="left" valign="top" width="20%">BINARY(4)</td>
|
|
<td align="left" valign="top" width="60%">Bytes returned</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<td align="center" valign="top">4</td>
|
|
<td align="center" valign="top">4</td>
|
|
<td align="left" valign="top" width="20%">BINARY(4)</td>
|
|
<td align="left" valign="top">Bytes available</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<td align="center" valign="top">8</td>
|
|
<td align="center" valign="top">8</td>
|
|
<td align="left" valign="top" width="20%">BINARY(4)</td>
|
|
<td align="left" valign="top">Offset to open time commands</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<td align="center" valign="top">12</td>
|
|
<td align="center" valign="top">C</td>
|
|
<td align="left" valign="top" width="20%">BINARY(4)</td>
|
|
<td align="left" valign="top">Size of open time commands</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<td align="center" valign="top"> </td>
|
|
<td align="center" valign="top"> </td>
|
|
<td align="left" valign="top" width="20%">CHAR(*)</td>
|
|
<td align="left" valign="top">Open time commands</td>
|
|
</tr>
|
|
</table>
|
|
|
|
<br>
|
|
|
|
|
|
<h3><a name="HDRFIELDC">Field Descriptions</a></h3>
|
|
|
|
<p><strong>Bytes available.</strong> The number of bytes of data available to
|
|
be returned. All available data is returned if enough space is provided.</p>
|
|
|
|
<p><strong>Bytes returned.</strong> The number of bytes of data returned.</p>
|
|
|
|
<p><strong>Offset to open time commands.</strong> The byte offset to the open
|
|
time commands from the beginning of the format.</p>
|
|
|
|
<p><strong>Open time commands.</strong> The open time commands, which contain
|
|
most of the file level commands to format the output.</p>
|
|
|
|
<p><strong>Size of open time commands.</strong> The size of the open time
|
|
commands, in bytes.</p>
|
|
|
|
<br>
|
|
|
|
|
|
<h3>Error Messages</h3>
|
|
|
|
<table width="100%" cellpadding="5">
|
|
<!-- cols="15 85" -->
|
|
<tr>
|
|
<th align="left" valign="top">Message ID</th>
|
|
<th align="left" valign="top">Error Message Text</th>
|
|
</tr>
|
|
|
|
<tr>
|
|
<td width="15%" valign="top">CPF24B4 E</td>
|
|
<td width="85%" valign="top">Severe error while addressing parameter list.</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<td valign="top">CPF2634 E</td>
|
|
<td valign="top">Not authorized to object &1.</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<td valign="top">CPF2702 E</td>
|
|
<td valign="top">Device description &1 not found.</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<td valign="top">CPF3CF1 E</td>
|
|
<td valign="top">Error code parameter not valid.</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<td valign="top">CPF3C19 E</td>
|
|
<td valign="top">Error occurred with receiver variable specified.</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<td valign="top">CPF3C21 E</td>
|
|
<td valign="top">Format name &1 is not valid.</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<td valign="top">CPF3C24 E</td>
|
|
<td valign="top">Length of the receiver variable is not valid.</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<td valign="top">CPF33E0 E</td>
|
|
<td valign="top">Incomplete set of attributes provided.</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<td valign="top">CPF334C E</td>
|
|
<td valign="top">Value &1 not valid for print data stream type.</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<td valign="top">CPF8105 E</td>
|
|
<td valign="top">Device description &4 damaged.</td>
|
|
</tr>
|
|
|
|
<tr>
|
|
<td valign="top">CPF9872 E</td>
|
|
<td valign="top">Program or service program &1 in library &2 ended.
|
|
Reason code &3.</td>
|
|
</tr>
|
|
</table>
|
|
|
|
<br>
|
|
<hr>
|
|
API introduced: V3R7
|
|
|
|
<hr>
|
|
<table cellpadding="2" cellspacing="2" align="center">
|
|
<tr align="center">
|
|
<td valign="middle" align="center"><a href="#Top_Of_Page">Top</a> | <a href=
|
|
"print1.htm">Print APIs</a> | <a href="aplist.htm">APIs by
|
|
category</a></td>
|
|
</tr>
|
|
</table>
|
|
</body>
|
|
</html>
|
|
|