Jump to content

SplDisplayControlPanel: Difference between revisions

From EDM2
Created page with "This function displays a control panel for a printer that is communicating bidirectionally. == Syntax == SplDisplayControlPanel(pszComputerName, pszPortName, pszDev..."
 
Ak120 (talk | contribs)
mNo edit summary
 
Line 1: Line 1:
This function displays a control panel for a printer that is communicating bidirectionally.  
This function displays a control panel for a printer that is communicating bidirectionally.


== Syntax ==  
==Syntax==
  SplDisplayControlPanel(pszComputerName,
  SplDisplayControlPanel(pszComputerName,
       pszPortName, pszDeviceID, pszControlPanel,
       pszPortName, pszDeviceID, pszControlPanel,
       hab, flCapabilities);
       hab, flCapabilities)


== Parameters ==
==Parameters==
; pszComputerName (PSZ) - input : Printer server name for displaying a remote printer panel from a client machine.  
;pszComputerName (PSZ) - input: Printer server name for displaying a remote printer panel from a client machine.
:This parameter is NULL for printers whose ports exist on the current machine.
;pszPortName (PSZ) - input: Printer port name.
:The name of the printer port for pszComputerName, used to display a control panel. Following is an example of a port name: LPT1
;pszDeviceID (PSZ) - input: Device ID, if known, for the printer connected to pszPortName.
;pszControlPanel (PSZ) - input: Name of control panel to call to display the front panel for this printer.
:This name can be one of the following:
:*The name registered with [[SplRegisterControlPanel]]
:*One of the control panel names returned by [[SplGetControlPanelList]]
;hab (HAB) - input : Anchor block handle.
;flCapabilities (ULONG) - input : Capabilities requested.
::FL_ADMIN - 0x00000001 - Set if an administrator wants the control panel.


: This parameter is NULL for printers whose ports exist on the current machine.
;rc (ULONG) - returns: Return codes.
 
::0 Success
; pszPortName (PSZ) - input : Printer port name.
::50 ERROR_NOT_SUPPORTED - A control panel for this printer is not supported by the called control panel DLL.
 
::123 ERROR_INVALID_NAME - pszName is not the name of a control panel DLL.
: The name of the printer port for pszComputerName, used to display a control panel. Following is an example of a port name:
  LPT1
 
; pszDeviceID (PSZ) - input : Device ID, if known, for the printer connected to pszPortName.
 
; pszControlPanel (PSZ) - input : Name of control panel to call to display the front panel for this printer.
 
: This name can be one of the following:
 
:*The name registered with SplRegisterControlPanel
:*One of the control panel names returned by SplGetControlPanelList
 
; hab (HAB) - input : Anchor block handle.
 
; flCapabilities (ULONG) - input : Capabilities requested.
 
:;FL_ADMIN - 0x00000001
::Set if an administrator wants the control panel.
 
== Returns ==
; rc (ULONG) - returns : Return codes.  
* 0 Success  
:;ERROR_INVALID_NAME(123)
::pszName is not the name of a control panel DLL.
 
:;ERROR_NOT_SUPPORTED(50)
::A control panel for this printer is not supported by the called control panel DLL.  
 
 
== Sample ==
<pre>
#define INCL_SPL
#define INCL_SPLBIDI
#include <os2.h>
 
PSZ      pszComputerName;  /*  Printer server name for displaying a remote printer panel from a client machine. */
PSZ      pszPortName;      /*  Printer port name. */
PSZ      pszDeviceID;      /*  Device ID, if known, for the printer connected to pszPortName. */
PSZ      pszControlPanel;  /*  Name of control panel to call to display the front panel for this printer. */
HAB      hab;              /*  Anchor block handle. */
ULONG    flCapabilities;  /*  Capabilities requested. */
ULONG    rc;              /*  Return codes. */
 
rc = SplDisplayControlPanel(pszComputerName,
      pszPortName, pszDeviceID, pszControlPanel,
      hab, flCapabilities);
 
</pre>


[[Category:Spl]]
[[Category:Spl]]

Latest revision as of 14:31, 13 December 2019

This function displays a control panel for a printer that is communicating bidirectionally.

Syntax

SplDisplayControlPanel(pszComputerName,
      pszPortName, pszDeviceID, pszControlPanel,
      hab, flCapabilities)

Parameters

pszComputerName (PSZ) - input
Printer server name for displaying a remote printer panel from a client machine.
This parameter is NULL for printers whose ports exist on the current machine.
pszPortName (PSZ) - input
Printer port name.
The name of the printer port for pszComputerName, used to display a control panel. Following is an example of a port name: LPT1
pszDeviceID (PSZ) - input
Device ID, if known, for the printer connected to pszPortName.
pszControlPanel (PSZ) - input
Name of control panel to call to display the front panel for this printer.
This name can be one of the following:
hab (HAB) - input
Anchor block handle.
flCapabilities (ULONG) - input
Capabilities requested.
FL_ADMIN - 0x00000001 - Set if an administrator wants the control panel.
rc (ULONG) - returns
Return codes.
0 Success
50 ERROR_NOT_SUPPORTED - A control panel for this printer is not supported by the called control panel DLL.
123 ERROR_INVALID_NAME - pszName is not the name of a control panel DLL.