Applies To: |
|
Summary: |
We use Webclient on site, and it is not
viable to set a default printer for all users (i.e a constant
[PRINTER]Port parameter on the servers INI file which will
propagate to all users), nor can we have a separate INI file for
each client. If the [PRINTER]Port parameter is left empty, then it will attempt to print to LPT1. This is not relevent to all our users, and setting up a mapped LPT1 port on every computer that 'may' use WebClient is not a viable solution. What is the best way of letting the user choose their own printer, either everytime, or just the first time on that local PC? |
Solution: |
This functionality can be achieved through
the Cicode function shown below. This can be used for normal
clients, as well as display clients. Copy the function below into a new Cicode file within your project, rename the function as desired, and link all your old print buttons to this new function. What does this function do?: * Firstly it will check for the INI parameter [PRINTER]Port to see if an existing printer has been defined - If you want users to select their own printers, ensure that this parameter is blank on the machine that prepared the Web deployment. - To confirm, after loading webclient on a machine, Check the INI file located at: C:\Documents & Settings\<username>\Local Settings\Temp\Citect\<DeploymentName>Citect.ini * Secondly, if the INI parameter is blank, instead of printing to LPT1, it will prompt the user to select a printer:
FUNCTION STRING
sPrinter; //Checks
[PRINTER]Port INI parameter for an existing
printer //If
there is no printer defined in INI, then prompt user to
choose IF
sPrinter
<> ""
THEN |
Keywords: |
webclient web client printer print select
slection selecting default |
Related Links
Attachments