Was this page helpful?
Your feedback about this content is important. Let us know what you think.
Additional feedback?
1500 characters remaining
SetLogo Method

PosPrinter.SetLogo Method (POS for .NET v1.12 SDK Documentation)

2/27/2008

Saves a data string as the top or bottom logo.

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

public abstract void SetLogo (
	PrinterLogoLocation location,
	string data
)
public abstract void SetLogo (
	PrinterLogoLocation location, 
	String data
)
public abstract function SetLogo (
	location : PrinterLogoLocation, 
	data : String
)

Parameters

location

Where the logo is to be set. Possible values are defined by the PrinterLogoLocation enumeration as PrinterLogoLocation.Top or PrinterLogoLocation.Bottom.

data

The characters that produce the logo. May consist of printable characters, escape sequences, carriage returns (13 decimal), and newline / line feed (10 decimal).

POS for .NET checks to make sure that the following is true:

  • The Printer device has been opened, claimed, and enabled; and

  • The specified location is either PrinterLogoLocation.Top or PrinterLogoLocation.Bottom.

If these validations succeed, the service object sets the logo. If either of these conditions is not met, the service object throws an exception.

The service object sets the logo by updating either the TopLogo or BottomLogo properties in the PrinterProperties helper class. After these protected properties are set, the service object can then check the properties when the application calls the PrintNormal, PrintTwoNormal, or PrintImmediate methods, to determine whether to add a top logo or bottom logo escape sequence to the print data.

Before it calls this method, the application must open, claim, and enable the device.

SetLogo may throw a PosControlException with the following ErrorCodes:

Value

Meaning

Illegal

One of the following conditions has occurred:

  • An invalid location was specified.

  • The printer is currently in Insertion mode.

  • The printer is currently in Removal mode.


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