Share via


PosPrinter.SlpLineChars Property

2/27/2008

Gets or sets the number of characters that the application wants to print on a slip line.

Namespace: Microsoft.PointOfService
Assembly: Microsoft.PointOfService (in microsoft.pointofservice.dll)

Syntax

'Declaration
Public MustOverride Property SlpLineChars As Integer
public abstract int SlpLineChars { get; set; }
public:
virtual property int SlpLineChars {
    int get () abstract;
    void set (int value) abstract;
}
/** @property */
public abstract int get_SlpLineChars ()

/** @property */
public abstract void set_SlpLineChars (int value)
public abstract function get SlpLineChars () : int

public abstract function set SlpLineChars (value : int)

Remarks

If the specified number of characters per line can be supported, the service object sets the line width to the specified value. If the exact width cannot be supported and the value is less than the maximum value allowed for the printer, later lines will be printed with the number that most closely supports the specified characters per line. (The service object should print the requested characters in the column positions closest to the side of the slip table at which the slip is aligned. For example, if the operator inserts the slip with the right edge against the table side, and if SlpLineChars is set to 36 and the printer prints 60 characters per line, the service object should add 24 spaces at the left margin, and print the characters in columns 25 through 60.)

If the specified line width cannot be supported and the value is greater than the maximum value allowed for the printer, then an error is returned. (For example, if SlpLineChars is set to 42 and the printer can print either 30 or 40 characters per line, the service object cannot support the request.)

Setting SlpLineChars may also update the SlpLineWidth, SlpLineHeight, and SlpLineSpacing properties, because the character pitch or font may be changed.

The service object sets SlpLineChars to the printer’s default line width when the device is first enabled following the Open method.

Accessing SlpLineChars may cause a PosControlException to be thrown with the following ErrorCode:

Value

Meaning

Illegal

The specified number of characters is greater than the maximum allowed for the printer.

Thread Safety

Any public static (Shared in Visual Basic) members of this type are thread-safe. Any instance members are not guaranteed to be thread-safe.

See Also

Reference

PosPrinter Class
PosPrinter Members
Microsoft.PointOfService Namespace
PosPrinter.SlpLineChars Property
SlpLineWidth
SlpLineHeight
SlpLineSpacing