<div class="content" name="RpcAsyncXcvData" uuid="10e4bb3a-05c1-4c2c-9974-a4d498c90d3d"><p><b>RpcAsyncXcvData</b> provides the means by which a <span><a href="a98de8d9-8e9e-4cd7-92f7-f9269206a41e#gt_1b5f368b-942b-40dd-84ea-fa9082916216" data-linktype="relative-path">port
monitor</a></span> client component can communicate with its server-side
counterpart, the actual port monitor hosted by the server.</p><p>The counterpart of this method in the Print System Remote
Protocol is <b>RpcXcvData</b>. All parameters not defined below are specified
in <span><a href="../ms-rprn/d42db7d5-f141-4466-8f47-0a4be14e2fc1" data-linktype="relative-path">[MS-RPRN]</a></span>
section <span><a href="../ms-rprn/bf9d2351-aac0-481e-9d37-05eb5cc961da" data-linktype="relative-path">3.1.4.6.5</a></span>.</p><dl>
<dd>
<div><pre> DWORD RpcAsyncXcvData(
   [in] PRINTER_HANDLE hXcv,
   [in, string] const wchar_t* pszDataName,
   [in, size_is(cbInputData)] unsigned char* pInputData,
   [in] DWORD cbInputData,
   [out, size_is(cbOutputData)] unsigned char* pOutputData,
   [in] DWORD cbOutputData,
   [out] DWORD* pcbOutputNeeded,
   [in, out] DWORD* pdwStatus
 );
</pre></div>
</dd></dl><p><b>hXcv: </b>A handle to a <span><a href="a98de8d9-8e9e-4cd7-92f7-f9269206a41e#gt_ac027425-6043-4ad3-be27-56a381b75d38" data-linktype="relative-path">port</a></span> object that has
been opened by using <b>RpcAsyncOpenPrinter</b> (section <span><a href="feddac6a-bd88-4989-95fb-715bd6ca796a" data-linktype="relative-path">3.1.4.1.1</a></span>).</p><p><b>Return Values: </b>This method returns zero to indicate
successful completion or a nonzero Win32 error code (<span><a href="../ms-erref/1bc92ddf-b79e-413c-bbaa-99a5281a6c90" data-linktype="relative-path">[MS-ERREF]</a></span>
section <span><a href="../ms-erref/18d8fbe8-a967-4f1c-ae50-99ca8e491d2d" data-linktype="relative-path">2.2</a></span>)
to indicate failure. Aside from the specific nonzero return values documented
in section <span><a href="93d1915d-4d9f-4ceb-90a7-e8f2a59adc29" data-linktype="relative-path">3.1.4</a></span>, the client
MUST treat any nonzero return value as a fatal error.</p><p><b>Exceptions Thrown:</b> This method MUST NOT throw any
exceptions other than those that are thrown by the underlying <span><a href="a98de8d9-8e9e-4cd7-92f7-f9269206a41e#gt_8a7f6700-8311-45bc-af10-82e10accd331" data-linktype="relative-path">RPC</a></span>
protocol <span><a href="../ms-rpce/290c38b1-92fe-4229-91e6-4fc376610c15" data-linktype="relative-path">[MS-RPCE]</a></span>.</p><p>This method MUST adhere to the parameter validation,
processing, and response requirements that are specified in [MS-RPRN] section
3.1.4.6.5.</p></div>