Getting Started
Leadtools.Printer Getting Started
Summary
LEADTOOLS Virtual Printer (Leadtools.Printer assembly)
The LEADTOOLS installation program installs a sample LEADTOOLS Virtual Printer for you. When you print to this printer from any Windows application, the example program will execute and you can then save the print job as a document file or raster image file.
For pointers to sample programs that demonstrate the LEADTOOLS Virtual Printer Driver features, see the table below:
.NET
Redistributables Paths
Path |
Target Platform |
<installdir>\Bin\net |
.NET 6+ |
Assembly - Namespace |
Comments
|
Leadtools.Printer.dll - Leadtools.Printer |
Main Virtual Printer demo showing all of the LEADTOOLS .NET Virtual Printer class library features.
This example also demonstrates using the LEADTOOLS Document Writers, to export the captured print job as any of the supported document formats.
|
Dependencies
Library |
Description |
Dependencies |
Leadtools.Printer.dll |
Core Library |
Leadtools.dll |
N/A | Not applicable | |
.NET Framework
Redistributables Paths
Path |
Target Platform |
<installdir>\Bin\DotNet4\Win32 |
x86 .NET 4 or 4.5 |
<installdir>\Bin\DotNet4\x64 |
x64 .NET 4 or 4.5 |
Assembly -
Namespace |
Comments |
Leadtools.Printer.dll - Leadtools.Printer |
Main Virtual Printer demo showing all of the LEADTOOLS .NET Virtual Printer class library features.
This example also demonstrates using the LEADTOOLS Document Writers, to export the captured print job as any of the supported document formats.
|
Dependencies
Library |
Description |
Dependencies |
Leadtools.Printer.dll |
Core Library |
Leadtools.dll
|
N/A | Not applicable | |
Sample Programs
Demo Name |
Source Code Path |
Description |
Printer Client |
\Examples\VirtualPrinter\DotNet\PrinterClientDemo\fx |
Implementation of LEADTOOLS client network printer assembly. Demonstrate Virtual Printer Client callbacks. |
Demo Name |
Source Code Path |
Description |
Printer Client Installer |
\Examples\VirtualPrinter\DotNet\PrinterClientInstallerDemo\fx |
Demonstrates the installation of LEADTOOLS Network Client Printer. |
Demo Name |
Source Code Path |
Pre-Compiled Executable Path |
Description |
Printer |
\Examples\VirtualPrinter\DotNet\PrinterDemo\fx |
\Bin\DotNet4\<Win32/x64>\PrinterDemo_Original.exe |
Install/Uninstall LEADTOOLS virtual printers. Lock/Unlock printers. Get/Set Printer Options. Save print job to Raster or Document formats. |
Demo Name |
Source Code Path |
Pre-Compiled Executable Path |
Description |
Printer Server Config |
\Examples\VirtualPrinter\DotNet\PrinterServerConfigDemo\fx |
\Bin\DotNet4\<Win32/x64>\PrinterServerConfigDemo_Original.exe |
Install/Uninstall LEADTOOLS virtual printers. Enable/Disable Network Printing for the specified printer. |
Demo Name |
Source Code Path |
Pre-Compiled Executable Path |
Description |
Printer Server |
\Examples\VirtualPrinter\DotNet\PrinterServerDemo\fx |
\Bin\DotNet4\<Win32/x64>\PrinterServerDemo_Original.exe |
Demonstrates receiving print jobs and saving them to disk files. Receives custom data from the client machine. The additional data can be any user specific data. |
Demo Name |
Source Code Path |
Pre-Compiled Executable Path |
Description |
Printer Server IIS Config |
\Examples\VirtualPrinter\DotNet\PrinterServerIISConfigDemo\fx |
\Bin\DotNet4\<Win32/x64>\PrinterServerIISConfigDemo_Original.exe |
Create/Remove the IIS virtual directory required to use LEADTOOLS Network Virtual Printer Service. |
Demo Name |
Source Code Path |
Pre-Compiled Executable Path |
Description |
VirtualPrinterDriverDeploymentTool Usage Guide |
\Examples\VirtualPrinter\DotNet\VirtualPrinterDriverDeploymentTool\fx |
\Bin\DotNet4\<Win32/x64>\VirtualPrinterDriverDeploymentTool.exe |
VirtualPrinterDriverDeploymentTool Usage Guide
Step 1: Creating the deployment package - Build and run the project on your development machine. Note, you'll generally want to run the 64-bit version for generating the package - Click the Create Package button: - If you're using the latest SDK, it should already default to your SDK's installation path. If not, simply use the Browse button and select the root for your SDK's installation: - Ensure the architecture you are wanting to deploy is selected. You'll generally want to include both 32-bit and x64 when generating the package, as you can choose which to use during deployment. - Finally, click the Create Package button: - You will be prompted for a save file location. For the purposes of demonstration, I've used "C:\temp\Package.zip": - A few moments after clicking Save you should see a dialog confirming the package was created:
Step 2: Copying files to deployment machine - Build the project under Release mode, with the architecture you'll be using for deployment, typically x64: - Once the project is built, go to the output folder (actual path may change based on architecture): \VirtualPrinterDriverDeploymentTool\bin\x64\Release - Copy the following files to a your deployment machine: > VirtualPrinterDriverDeploymentTool.exe > Package.zip [created in Step 1]
Step 3: Deploying - Run the VirtualPrinterDriverDeploymentTool.exe as administrator - Click the Deploy Package button: - Choose your deployment destination. For the purposes of example, I've changed the path to "(LEADTOOLS Installation folder)": - Ensure the architecture options are configured properly. If you would like to include the 32-bit driver during a 64-bit installation, that is also available: - The last option is mainly used for development purposes. By checking this box, it will deploy to a folder structure similar to the full SDK. By not checking this box, it will deploy to a simplified folder structure. > Structure when not checked: ++ OutputDir\PrinterDriver ++ OutputDir\Virtual Printer > Structure when checked (integrated deployment): ++ OutputDir\Bin\Common\PrinterDriver ++ OutputDir\Redist\Virtual Printer
- When all options are configured, click the Deploy Package button: - You will then be prompted to open the ZIP created during Step 1: - After clicking Open a diagnostic log will appear listing each step of the installation process. - If you have not installed these drivers before, you will be prompted by a Windows Security dialog. Ensure you click Install. Checking Always trust is optional of course: - Once everything has been installed, you should see the following success dialog. And as the dialog states, a restart may be required. - If an error has occurred, ensure you have followed any instructions listed. If you are unable to correct the deployment issue manually, please contact the LEADTOOLS Support department: support@leadtools.com
Step 4: Uninstalling - Run the VirtualPrinterDriverDeploymentTool.exe as admin: - Click the Uninstall button: - Ensure your deployment directory is selected (this will typically be saved from the previous deployment using .NET's application settings): - Click the Uninstall button: - You will now see a diagnostic log displaying all uninstallation steps. - If you had previously integrated your installation, or the path has "LEADTOOLS ##" in the name, it will prompt during uninstallation if you'd like to delete the files. This allows users to test on their development machine without worrying it will delete the required deployment files: - Once it has uninstalled, you should see the following success message: - Again, if any errors occur, there will be information in the log. If any assistance is required for an error during uninstallation, please contact the LEADTOOLS support department at support@leadtools.com.
Copyright (c) 1991-2023 LEAD Technologies, Inc. All Rights Reserved. |
See Also
Reference
Introduction
Getting Started (Guide to Example Programs)
Programming With LEADTOOLS Virtual Printer
Convert EMF to RasterImage