Paxar 6039 Printer User Manual


 
Developing Applications 2-3
C# Sample
using Ultra; // Platinum Library
string fmtUPCA = "{F,1,A,R,E,200,200,\"UPCA\"|"
+ "C,150,49,0,50,8,8,A,L,0,0,\"Demo C Sharp\",1|"
+ "B,1,12,F,25,28,1,4,100,7,L,0|}";
Ultra.Print rPrint = new Print(); // Instantiate Print
// class
rPrint.ClearError(); // Clear any errors
if (!rPrint.IsBatteryOKToPrint) // Check Battery
MessageBox.Show("Low Battery", "Battery Check");
else
{
//--Print Format and Batch Data
rPrint.Text = fmtUPCA;
rPrint.Text = "{B,1,N,1|E,0,0,1,1,0,1|
rPrint.Text = 1,\"" + txtUPC.Text + "\"|}";
}
This example prints the data stored in the fmtUPCA string and the data
stored in the txtUPC.Text field. The rPrint.Text lines contain the
batch data.