LinePrinter Print Sample “Example XP FF 3.5” for VS 2008

 

 

  1. Sample Overview
  2. Requirements and Dependencies
  3. Topics
  4. Building the Sample
  5. Running the Sample
  6. Common Issues
  7. Notes 

Sample Overview

This sample demonstrates the use of the Honeywell LinePrinter Utility to obtain a list of possible printers from the LinePrinter configuration file, ITC_CONFIG.XML, and create a simple report printout.

 

There are seven files that should be in your development directory when you start this project. They are:

 

File Name

Purpose

Example1.sln

Microsoft Solution file.

Example1.csproj

Microsoft Project file.

AssemblyInfo.cs

Standard Visual Studio generated file.

Form1.cs

Sample Code.

Form1.resx

Microsoft Resource file.

ITC_CONFIG.XML

Configurations file for LinePrinter use.  May be modified to customize your printing requirements.

Readme.htm

This file.

 

Requirements and Dependencies

There are no special requirements or dependencies for building this application.

Topics

BoldOff BoldOn Close EnumeratePrinters FooterEventEx FooterEventHandler FormFeed HeaderEventEx HeaderEventHandler LinePrinter LinePrinterException NewLineNoOrphan Open StatusMessageEventEx StatusMessageEventHandler StatusMessageTypes WarningMessageEventEx WarningMessageEventHandler Write

Building the Sample

Load the project in Visual Studio 2008 and select “build”. 

 

Please see Common Issues and Notes below for additional important information on building and running the application.

Running the Sample

Start the application by clicking on the executable or starting the debugger. 

Select the appropriate printer from the combo box.

Enter the printer address and the Bluetooth PIN or Wi-Fi port number if appropriate.

Select the desired options. 

Make sure the printer is on and connected and press Print.

 

Common Issues

  1. You may receive the following warning when building this project.

    There is a circular reference involving the import of file "C:\WINDOWS\Microsoft.NET\Framework\v3.5\Microsoft.CompactFramework.CSharp.targets". This file may have been imported more than once, or you may have attempted to import the main project file. All except the first instance of this file will be ignored.

    This warning would appear to be common to Visual Studio 2008 .NET Projects and may be ignored.
  2. For non default installations of the Printing Resource Kit, you may need to modify the reference in the project for the LinePrinter assembly.

 

 

Notes

General:

  1. The configuration file, ITC_CONFIG.XML, or the computer settings may need to be modified to work with your printers.

 

Networked Printers:

  1. You will need to modify the configuration file with the IP Address and Port of your particular printer for network printing.  These values can often be found by printing a test page on the printer.  You may also need to configure the computer to operate on the same network as the printers.

 

Bluetooth Printers:

  1. The computer will need to be Bluetooth enabled.  You will need to configure the computer's Bluetooth settings.

 

Serial Printers:

  1. You will need to modify the configuration file with the proper serial port information for some printers and computers.

 

To modify your mobile computer settings, please see the documentation for that device.

To configure the configuration file, please see the “Printer Configuration File Components” section of the “Printing Resource Kit User's Guide” documentation.