SlipPrintJob SlipPrintJob SlipPrintJob SlipPrintJob Class

Definition

Represents a set of printing instructions that you want to run on the slip printer station.

public : sealed class SlipPrintJob : IPosPrinterJob, IReceiptOrSlipJobpublic sealed class SlipPrintJob : IPosPrinterJob, IReceiptOrSlipJobPublic NotInheritable Class SlipPrintJob Implements IPosPrinterJob, IReceiptOrSlipJob// You can use this class in JavaScript.
Attributes
Windows 10 requirements
Device family
Windows 10 (introduced v10.0.10240.0 - for Xbox, see UWP features that aren't yet supported on Xbox)
API contract
Windows.Foundation.UniversalApiContract (introduced v1)

Remarks

To create a new print job for the slip printer, call ClaimedSlipPrinter.CreateJob. The created print job object is valid as long as the ClaimedSlipPrinter object that created it is valid.

Methods

DrawRuledLine(String, PosPrinterLineDirection, UInt32, PosPrinterLineStyle, UInt32) DrawRuledLine(String, PosPrinterLineDirection, UInt32, PosPrinterLineStyle, UInt32) DrawRuledLine(String, PosPrinterLineDirection, UInt32, PosPrinterLineStyle, UInt32) DrawRuledLine(String, PosPrinterLineDirection, UInt32, PosPrinterLineStyle, UInt32)

Adds an instruction to the print job to print a drawn, ruled line on the paper of the slip printer station.

public : void DrawRuledLine(PlatForm::String positionList, PosPrinterLineDirection lineDirection, unsigned int lineWidth, PosPrinterLineStyle lineStyle, unsigned int lineColor)public void DrawRuledLine(String positionList, PosPrinterLineDirection lineDirection, UInt32 lineWidth, PosPrinterLineStyle lineStyle, UInt32 lineColor)Public Function DrawRuledLine(positionList As String, lineDirection As PosPrinterLineDirection, lineWidth As UInt32, lineStyle As PosPrinterLineStyle, lineColor As UInt32) As void// You can use this method in JavaScript.
Parameters
positionList
PlatForm::String String String String

The position parameters for the ruled line. The character string for positionList differs depending on whether lineDirection specifies a horizontal ruled line or a vertical ruled line.

lineDirection
PosPrinterLineDirection PosPrinterLineDirection PosPrinterLineDirection PosPrinterLineDirection

The direction in which to print the ruled line.

lineWidth
unsigned int UInt32 UInt32 UInt32

The width of the ruled line that the print should print. The unit of width is dot. If an unsupported value is specified, the best fit value for the printer is used.

lineStyle
PosPrinterLineStyle PosPrinterLineStyle PosPrinterLineStyle PosPrinterLineStyle

The appearance of the ruled line, such as whether it is solid or broken, or single or double.

lineColor
unsigned int UInt32 UInt32 UInt32

The color of the ruled line, as an integer value that is equal to the value of the cartridge constant used in the ClaimedSlipPrinter.ColorCartridge property. If an unsupported value is specified, the printing results may be unpredictable.

See Also

ExecuteAsync() ExecuteAsync() ExecuteAsync() ExecuteAsync()

Runs the print job on the slip printer station asynchronously.

public : IAsyncOperation<PlatForm::Boolean> ExecuteAsync()public IAsyncOperation<bool> ExecuteAsync()Public Function ExecuteAsync() As IAsyncOperation( Of bool )// You can use this method in JavaScript.
Returns

The operation to run the print job. This operation returns true if the print job succeeds; otherwise, the operation returns false.

Remarks

The print job is sent to the claimed printer station object that created the print job. The claimed printer station object must remain valid when calling this method.

Print(String) Print(String) Print(String) Print(String)

Adds an instruction to the print job to print the specified text on the slip printer station.

public : void Print(PlatForm::String data)public void Print(String data)Public Function Print(data As String) As void// You can use this method in JavaScript.
Parameters
data
PlatForm::String String String String

The text to print on the slip printer station.

Remarks

If ClaimedPosPrinter.IsCharacterSetMappingEnabled is true, the text is mapped to the font on the printer that ClaimedPosPrinter.CharacterSet specifies. If ClaimedPosPrinter.IsCharacterSetMappingEnabled is false, the driver or provider sends the low byte of each Unicode character to the printer verbatim.

PrintBarcode(String, UInt32, UInt32, UInt32, PosPrinterBarcodeTextPosition, PosPrinterAlignment) PrintBarcode(String, UInt32, UInt32, UInt32, PosPrinterBarcodeTextPosition, PosPrinterAlignment) PrintBarcode(String, UInt32, UInt32, UInt32, PosPrinterBarcodeTextPosition, PosPrinterAlignment) PrintBarcode(String, UInt32, UInt32, UInt32, PosPrinterBarcodeTextPosition, PosPrinterAlignment)

Adds an instruction to the print job to print a barcode on the slip printer station with the specified data and symbology.

public : void PrintBarcode(PlatForm::String data, unsigned int symbology, unsigned int height, unsigned int width, PosPrinterBarcodeTextPosition textPosition, PosPrinterAlignment alignment)public void PrintBarcode(String data, UInt32 symbology, UInt32 height, UInt32 width, PosPrinterBarcodeTextPosition textPosition, PosPrinterAlignment alignment)Public Function PrintBarcode(data As String, symbology As UInt32, height As UInt32, width As UInt32, textPosition As PosPrinterBarcodeTextPosition, alignment As PosPrinterAlignment) As void// You can use this method in JavaScript.
Parameters
data
PlatForm::String String String String

The data to represent as a barcode.

symbology
unsigned int UInt32 UInt32 UInt32

The symbology (encoding) of the barcode.

height
unsigned int UInt32 UInt32 UInt32

The height of the barcode, in pixels.

width
unsigned int UInt32 UInt32 UInt32

The width of the barcode, in pixels.

textPosition
PosPrinterBarcodeTextPosition PosPrinterBarcodeTextPosition PosPrinterBarcodeTextPosition PosPrinterBarcodeTextPosition

The vertical position of the barcode text relative to the barcode.

alignment
PosPrinterAlignment PosPrinterAlignment PosPrinterAlignment PosPrinterAlignment

The horizontal alignment of the barcode on the page.

PrintBarcodeCustomAlign(String, UInt32, UInt32, UInt32, PosPrinterBarcodeTextPosition, UInt32) PrintBarcodeCustomAlign(String, UInt32, UInt32, UInt32, PosPrinterBarcodeTextPosition, UInt32) PrintBarcodeCustomAlign(String, UInt32, UInt32, UInt32, PosPrinterBarcodeTextPosition, UInt32) PrintBarcodeCustomAlign(String, UInt32, UInt32, UInt32, PosPrinterBarcodeTextPosition, UInt32)

Adds an instruction to the print job to print a barcode on the slip printer station with the specified data, symbology, and custom alignment.

public : void PrintBarcodeCustomAlign(PlatForm::String data, unsigned int symbology, unsigned int height, unsigned int width, PosPrinterBarcodeTextPosition textPosition, unsigned int alignmentDistance)public void PrintBarcodeCustomAlign(String data, UInt32 symbology, UInt32 height, UInt32 width, PosPrinterBarcodeTextPosition textPosition, UInt32 alignmentDistance)Public Function PrintBarcodeCustomAlign(data As String, symbology As UInt32, height As UInt32, width As UInt32, textPosition As PosPrinterBarcodeTextPosition, alignmentDistance As UInt32) As void// You can use this method in JavaScript.
Parameters
data
PlatForm::String String String String

The data to represent as a barcode.

symbology
unsigned int UInt32 UInt32 UInt32

The symbology (encoding) of the barcode.

height
unsigned int UInt32 UInt32 UInt32

The height of the barcode, in pixels.

width
unsigned int UInt32 UInt32 UInt32

The width of the barcode, in pixels.

textPosition
PosPrinterBarcodeTextPosition PosPrinterBarcodeTextPosition PosPrinterBarcodeTextPosition PosPrinterBarcodeTextPosition

The vertical position of the barcode text relative to the barcode.

alignmentDistance
unsigned int UInt32 UInt32 UInt32

The distance from the leftmost print column to the start of the barcode, expressed in the unit of measurement indicated by the ClaimedPosPrinter.MapMode property.

PrintBitmap(BitmapFrame, PosPrinterAlignment) PrintBitmap(BitmapFrame, PosPrinterAlignment) PrintBitmap(BitmapFrame, PosPrinterAlignment) PrintBitmap(BitmapFrame, PosPrinterAlignment)

Adds an instruction to the print job to print the specified bitmap with the specified standard horizontal placement on the slip printer station.

public : void PrintBitmap(BitmapFrame bitmap, PosPrinterAlignment alignment)public void PrintBitmap(BitmapFrame bitmap, PosPrinterAlignment alignment)Public Function PrintBitmap(bitmap As BitmapFrame, alignment As PosPrinterAlignment) As void// You can use this method in JavaScript.
Parameters
bitmap
BitmapFrame BitmapFrame BitmapFrame BitmapFrame

Information about the bitmap that you want to print.

alignment
PosPrinterAlignment PosPrinterAlignment PosPrinterAlignment PosPrinterAlignment

An enumeration value that specifies a standard horizontal placement on the page for the bitmap, such as left-aligned, centered, or right-aligned.

See Also

PrintBitmap(BitmapFrame, PosPrinterAlignment, UInt32) PrintBitmap(BitmapFrame, PosPrinterAlignment, UInt32) PrintBitmap(BitmapFrame, PosPrinterAlignment, UInt32) PrintBitmap(BitmapFrame, PosPrinterAlignment, UInt32)

Adds an instruction to the print job to print the specified bitmap with the specified width and a standard horizontal placement on the slip printer station.

public : void PrintBitmap(BitmapFrame bitmap, PosPrinterAlignment alignment, unsigned int width)public void PrintBitmap(BitmapFrame bitmap, PosPrinterAlignment alignment, UInt32 width)Public Function PrintBitmap(bitmap As BitmapFrame, alignment As PosPrinterAlignment, width As UInt32) As void// You can use this method in JavaScript.
Parameters
bitmap
BitmapFrame BitmapFrame BitmapFrame BitmapFrame

Information about the bitmap that you want to print.

alignment
PosPrinterAlignment PosPrinterAlignment PosPrinterAlignment PosPrinterAlignment

An enumeration value that specifies a standard horizontal placement on the page for the bitmap, such as left-aligned, centered, or right-aligned.

width
unsigned int UInt32 UInt32 UInt32

The width to use for printing the bitmap, expressed in the unit of measurement indicated by the ClaimedPosPrinter.MapMode property.

See Also

PrintCustomAlignedBitmap(BitmapFrame, UInt32) PrintCustomAlignedBitmap(BitmapFrame, UInt32) PrintCustomAlignedBitmap(BitmapFrame, UInt32) PrintCustomAlignedBitmap(BitmapFrame, UInt32)

Adds an instruction to the print job to print the specified bitmap at the specified distance from the leftmost print column on the slip printer station.

public : void PrintCustomAlignedBitmap(BitmapFrame bitmap, unsigned int alignmentDistance)public void PrintCustomAlignedBitmap(BitmapFrame bitmap, UInt32 alignmentDistance)Public Function PrintCustomAlignedBitmap(bitmap As BitmapFrame, alignmentDistance As UInt32) As void// You can use this method in JavaScript.
Parameters
bitmap
BitmapFrame BitmapFrame BitmapFrame BitmapFrame

Information about the bitmap that you want to print.

alignmentDistance
unsigned int UInt32 UInt32 UInt32

The distance from the leftmost print column to the start of the bitmap, expressed in the unit of measurement indicated by the ClaimedPosPrinter.MapMode property.

See Also

PrintCustomAlignedBitmap(BitmapFrame, UInt32, UInt32) PrintCustomAlignedBitmap(BitmapFrame, UInt32, UInt32) PrintCustomAlignedBitmap(BitmapFrame, UInt32, UInt32) PrintCustomAlignedBitmap(BitmapFrame, UInt32, UInt32)

Adds an instruction to the print job to print the specified bitmap with the specified width and at the specified distance from the leftmost print column on the slip printer station.

public : void PrintCustomAlignedBitmap(BitmapFrame bitmap, unsigned int alignmentDistance, unsigned int width)public void PrintCustomAlignedBitmap(BitmapFrame bitmap, UInt32 alignmentDistance, UInt32 width)Public Function PrintCustomAlignedBitmap(bitmap As BitmapFrame, alignmentDistance As UInt32, width As UInt32) As void// You can use this method in JavaScript.
Parameters
bitmap
BitmapFrame BitmapFrame BitmapFrame BitmapFrame

Information about the bitmap that you want to print.

alignmentDistance
unsigned int UInt32 UInt32 UInt32

The distance from the leftmost print column to the start of the bitmap, expressed in the unit of measurement indicated by the ClaimedPosPrinter.MapMode property.

width
unsigned int UInt32 UInt32 UInt32

The width to use for printing the bitmap, expressed in the unit of measurement indicated by the ClaimedPosPrinter.MapMode property.

See Also

PrintLine() PrintLine() PrintLine() PrintLine()

Adds an instruction to the print job to print a newline character on the slip printer station.

public : void PrintLine()public void PrintLine()Public Function PrintLine() As void// You can use this method in JavaScript.
See Also

PrintLine(String) PrintLine(String) PrintLine(String) PrintLine(String)

Adds an instruction to the print job to print a line of text on the slip printer station.

public : void PrintLine(PlatForm::String data)public void PrintLine(String data)Public Function PrintLine(data As String) As void// You can use this method in JavaScript.
Parameters
data
PlatForm::String String String String

The line of text to print.

See Also

PrintSavedBitmap(UInt32) PrintSavedBitmap(UInt32) PrintSavedBitmap(UInt32) PrintSavedBitmap(UInt32)

Adds an instruction to the print job to print a bitmap on the slip printer station by using the information that you saved about the bitmap and how to print it when you called the SetBitmap or SetCustomAlignedBitmap method.

public : void PrintSavedBitmap(unsigned int bitmapNumber)public void PrintSavedBitmap(UInt32 bitmapNumber)Public Function PrintSavedBitmap(bitmapNumber As UInt32) As void// You can use this method in JavaScript.
Parameters
bitmapNumber
unsigned int UInt32 UInt32 UInt32

The number that you assigned to the bitmap that you want to print when you called SetBitmap or SetCustomAlignedBitmap.

Remarks

The bitmap rotation setting that you specify by calling SlipPrintJob.SetPrintRotation may not apply to bitmaps that you saved to the printer.

See Also

SetBarcodeRotation(PosPrinterRotation) SetBarcodeRotation(PosPrinterRotation) SetBarcodeRotation(PosPrinterRotation) SetBarcodeRotation(PosPrinterRotation)

Sets the rotation of the barcode on the page on the slip printer station.

public : void SetBarcodeRotation(PosPrinterRotation value)public void SetBarcodeRotation(PosPrinterRotation value)Public Function SetBarcodeRotation(value As PosPrinterRotation) As void// You can use this method in JavaScript.
Parameters
value
PosPrinterRotation PosPrinterRotation PosPrinterRotation PosPrinterRotation

The rotation of the barcode on the page on the slip printer station.

SetBitmap(UInt32, BitmapFrame, PosPrinterAlignment) SetBitmap(UInt32, BitmapFrame, PosPrinterAlignment) SetBitmap(UInt32, BitmapFrame, PosPrinterAlignment) SetBitmap(UInt32, BitmapFrame, PosPrinterAlignment)

Saves information about a bitmap and a standard horizontal placement that you want to use to print that bitmap on the slip printer station, so that you can use the PrintSavedBitmap method to add that information to the print job later.

public : void SetBitmap(unsigned int bitmapNumber, BitmapFrame bitmap, PosPrinterAlignment alignment)public void SetBitmap(UInt32 bitmapNumber, BitmapFrame bitmap, PosPrinterAlignment alignment)Public Function SetBitmap(bitmapNumber As UInt32, bitmap As BitmapFrame, alignment As PosPrinterAlignment) As void// You can use this method in JavaScript.
Parameters
bitmapNumber
unsigned int UInt32 UInt32 UInt32

The number that you want to assign to this bitmap. You can set two bitmaps, numbered 1 and 2. Use this number with the PrintSavedBitmap method later to add the print instructions to the print job.

bitmap
BitmapFrame BitmapFrame BitmapFrame BitmapFrame

Information about the bitmap that you want to print.

alignment
PosPrinterAlignment PosPrinterAlignment PosPrinterAlignment PosPrinterAlignment

An enumeration value that specifies a standard horizontal placement on the page for the bitmap, such as left-aligned, centered, or right-aligned.

Remarks

If the printer for the print job has non-volatile bitmap storage, this method saves the bitmap to the printer hardware, which can cause wear and damage to the flash storage for the printer.

See Also

SetBitmap(UInt32, BitmapFrame, PosPrinterAlignment, UInt32) SetBitmap(UInt32, BitmapFrame, PosPrinterAlignment, UInt32) SetBitmap(UInt32, BitmapFrame, PosPrinterAlignment, UInt32) SetBitmap(UInt32, BitmapFrame, PosPrinterAlignment, UInt32)

Saves information about a bitmap, along with the width and a standard horizontal placement that you want to use to print that bitmap on the slip printer station, so that you can use the PrintSavedBitmap method to add that information to the print job later.

public : void SetBitmap(unsigned int bitmapNumber, BitmapFrame bitmap, PosPrinterAlignment alignment, unsigned int width)public void SetBitmap(UInt32 bitmapNumber, BitmapFrame bitmap, PosPrinterAlignment alignment, UInt32 width)Public Function SetBitmap(bitmapNumber As UInt32, bitmap As BitmapFrame, alignment As PosPrinterAlignment, width As UInt32) As void// You can use this method in JavaScript.
Parameters
bitmapNumber
unsigned int UInt32 UInt32 UInt32

The number that you want to assign to this bitmap. You can set two bitmaps, numbered 1 and 2. Use this number with the PrintSavedBitmap method later to add the print instructions to the print job.

bitmap
BitmapFrame BitmapFrame BitmapFrame BitmapFrame

Information about the bitmap that you want to print.

alignment
PosPrinterAlignment PosPrinterAlignment PosPrinterAlignment PosPrinterAlignment

An enumeration value that specifies a standard horizontal placement on the page for the bitmap, such as left-aligned, centered, or right-aligned.

width
unsigned int UInt32 UInt32 UInt32

The width to use for printing the bitmap, expressed in the unit of measurement indicated by the ClaimedPosPrinter.MapMode property.

Remarks

If the printer for the print job has non-volatile bitmap storage, this method saves the bitmap to the printer hardware, which can cause wear and damage to the flash storage for the printer.

See Also

SetCustomAlignedBitmap(UInt32, BitmapFrame, UInt32) SetCustomAlignedBitmap(UInt32, BitmapFrame, UInt32) SetCustomAlignedBitmap(UInt32, BitmapFrame, UInt32) SetCustomAlignedBitmap(UInt32, BitmapFrame, UInt32)

Saves information about a bitmap and the distance from the leftmost print column at which you want to print that bitmap on the slip printer station, so that you can use the PrintSavedBitmap method to add that information to the print job later.

public : void SetCustomAlignedBitmap(unsigned int bitmapNumber, BitmapFrame bitmap, unsigned int alignmentDistance)public void SetCustomAlignedBitmap(UInt32 bitmapNumber, BitmapFrame bitmap, UInt32 alignmentDistance)Public Function SetCustomAlignedBitmap(bitmapNumber As UInt32, bitmap As BitmapFrame, alignmentDistance As UInt32) As void// You can use this method in JavaScript.
Parameters
bitmapNumber
unsigned int UInt32 UInt32 UInt32

The number that you want to assign to this bitmap. You can set two bitmaps, numbered 1 and 2. Use this number with the PrintSavedBitmap method later to add the print instructions to the print job.

bitmap
BitmapFrame BitmapFrame BitmapFrame BitmapFrame

Information about the bitmap that you want to print.

alignmentDistance
unsigned int UInt32 UInt32 UInt32

The distance from the leftmost print column to the start of the bitmap, expressed in the unit of measurement indicated by the ClaimedPosPrinter.MapMode property.

See Also

SetCustomAlignedBitmap(UInt32, BitmapFrame, UInt32, UInt32) SetCustomAlignedBitmap(UInt32, BitmapFrame, UInt32, UInt32) SetCustomAlignedBitmap(UInt32, BitmapFrame, UInt32, UInt32) SetCustomAlignedBitmap(UInt32, BitmapFrame, UInt32, UInt32)

Saves information about a bitmap, along with the width and the distance from the leftmost print column that you want to use to print that bitmap on the slip printer station, so that you can use the PrintSavedBitmap method to add that information to the print job later.

public : void SetCustomAlignedBitmap(unsigned int bitmapNumber, BitmapFrame bitmap, unsigned int alignmentDistance, unsigned int width)public void SetCustomAlignedBitmap(UInt32 bitmapNumber, BitmapFrame bitmap, UInt32 alignmentDistance, UInt32 width)Public Function SetCustomAlignedBitmap(bitmapNumber As UInt32, bitmap As BitmapFrame, alignmentDistance As UInt32, width As UInt32) As void// You can use this method in JavaScript.
Parameters
bitmapNumber
unsigned int UInt32 UInt32 UInt32

The number that you want to assign to this bitmap. You can set two bitmaps, numbered 1 and 2. Use this number with the PrintSavedBitmap method later to add the print instructions to the print job.

bitmap
BitmapFrame BitmapFrame BitmapFrame BitmapFrame

Information about the bitmap that you want to print.

alignmentDistance
unsigned int UInt32 UInt32 UInt32

The distance from the leftmost print column to the start of the bitmap, expressed in the unit of measurement indicated by the ClaimedPosPrinter.MapMode property.

width
unsigned int UInt32 UInt32 UInt32

The width to use for printing the bitmap, expressed in the unit of measurement indicated by the ClaimedPosPrinter.MapMode property.

See Also

SetPrintArea(Rect) SetPrintArea(Rect) SetPrintArea(Rect) SetPrintArea(Rect)

Sets the area of the page on which the slip printer station can print the job.

public : void SetPrintArea(Rect value)public void SetPrintArea(Rect value)Public Function SetPrintArea(value As Rect) As void// You can use this method in JavaScript.
Parameters
value
Rect Rect Rect Rect

The area of the page on which the slip printer station can print the job.

Remarks

When you call this method for a print job, all instructions in the print job run within the specified print area, including the instructions that you added to the job before you called SlipPrintJob.SetPrintArea.

SetPrintRotation(PosPrinterRotation, Boolean) SetPrintRotation(PosPrinterRotation, Boolean) SetPrintRotation(PosPrinterRotation, Boolean) SetPrintRotation(PosPrinterRotation, Boolean)

Sets the rotation of the text or image on the page on the slip printer station.

public : void SetPrintRotation(PosPrinterRotation value, bool includeBitmaps)public void SetPrintRotation(PosPrinterRotation value, Boolean includeBitmaps)Public Function SetPrintRotation(value As PosPrinterRotation, includeBitmaps As Boolean) As void// You can use this method in JavaScript.
Parameters
value
PosPrinterRotation PosPrinterRotation PosPrinterRotation PosPrinterRotation

The rotation of the text or image on the page.

includeBitmaps
bool Boolean Boolean Boolean

Whether bitmaps should also be rotated. This setting takes effect only for subsequent calls to PrintBitmap, and may not apply to saved bitmaps that you print using PrintSavedBitmap.

Remarks

This rotation setting persists beyond the current print job.