3.1.4.2.9 RpcAsyncGetCorePrinterDrivers (Opnum 64)
RpcAsyncGetCorePrinterDrivers gets the GUID, versions, and publish dates of the specified core printer drivers, and the paths to their packages.
The counterpart of this method in the Print System Remote Protocol is RpcGetCorePrinterDrivers ([MS-RPRN] section 3.1.4.4.9).
-
HRESULT RpcAsyncGetCorePrinterDrivers( [in] handle_t hRemoteBinding, [in, string, unique] const wchar_t* pszServer, [in, string] const wchar_t* pszEnvironment, [in] DWORD cchCoreDrivers, [in, size_is(cchCoreDrivers)] const wchar_t* pszzCoreDriverDependencies, [in] DWORD cCorePrinterDrivers, [out, size_is(cCorePrinterDrivers)] CORE_PRINTER_DRIVER* pCorePrinterDrivers );
hRemoteBinding: An RPC explicit binding handle.
pszServer: A pointer to a string that specifies the name of the print server from which to get the core printer driver information. This string contains a server name that is identical to the server name that was used to create the hRemoteBinding parameter. For details on RPC bind handles, see [MS-RPCE]. For rules governing print server names, see [MS-RPRN] section 2.2.4.16.
pszEnvironment: A pointer to a string that specifies the environment name for which the core printer driver information will be returned. For rules governing environment names, see [MS-RPRN] section 2.2.4.4.
cchCoreDrivers: The size, in bytes, of the buffer that is referenced by the pszzCoreDriverDependencies parameter.
pszzCoreDriverDependencies: A pointer to a multisz that contains a list of IDs <22> of the core printer drivers to be retrieved.
-
A print client SHOULD obtain this list of IDs as follows:
Call RpcAsyncGetPrinterDriver (section 3.1.4.2.1) with a Level parameter value of 0x00000008.
A _DRIVER_INFO_8 custom-marshaled structure ([MS-RPRN] section 2.2.2.4.8) is returned in the pDriver parameter.
In the _DRIVER_INFO_8, the szzCoreDependenciesOffset field contains an offset to a multisz that contains the list of IDs.
cCorePrinterDrivers: The count of CORE_PRINTER_DRIVER structures (section 2.2.8) that are contained in the buffer that is pointed to by the pCorePrinterDrivers parameter. It equals the number of IDs that are specified in the multisz that is pointed to by the pszzCoreDriverDependencies parameter.
pCorePrinterDrivers: A pointer to a buffer that receives an array of CORE_PRINTER_DRIVER structures.
Return Values: This method returns either an HRESULT success value ([MS-ERREF] section 2.1) or an HRESULT error value to indicate failure.
Exceptions Thrown: This method MUST NOT throw any exceptions other than those that are thrown by the underlying RPC protocol [MS-RPCE].
This method MUST adhere to the parameter validation, processing, and response requirements that are specified in [MS-RPRN] section 3.1.4.4.9.