FiscalPrinter.PrintRecTotal Method
2/27/2008
Checks and prints the current receipt total on the station defined by the FiscalReceiptStation property and tenders a payment.
Namespace: Microsoft.PointOfService
Assembly: Microsoft.PointOfService (in microsoft.pointofservice.dll)
Syntax
'Declaration
Public MustOverride Sub PrintRecTotal ( _
total As Decimal, _
payment As Decimal, _
description As String _
)
public abstract void PrintRecTotal (
decimal total,
decimal payment,
string description
)
public:
virtual void PrintRecTotal (
Decimal total,
Decimal payment,
String^ description
) abstract
public abstract void PrintRecTotal (
Decimal total,
Decimal payment,
String description
)
public abstract function PrintRecTotal (
total : decimal,
payment : decimal,
description : String
)
Parameters
- total
Application-computed receipt total.
- payment
Amount of payment tendered.
- description
Text description of the payment or the index of a predefined payment description.
Remarks
If CapCheckTotal is true, the total is compared to the total calculated by the printer. If the totals match, the total is printed on both the receipt and journal along with some fixed text. If the results do not match, the receipt is automatically canceled. If CapCheckTotal is false, the total is printed on the receipt and journal and the parameter is never compared to the total computed by the printer.
If CapPredefinedPaymentLines is true, the description parameter contains the index of one of the printer’s predefined payment descriptions. The index is typically a single character of the alphabet. The set of allowed values for this index is to be described in the description of the service object and stored in the PredefinedPaymentLines property.
If payment = total, a line containing the description and payment is printed. The PrinterState property is set to FiscalReceiptEnding.
If payment > total, a line containing the description and payment is printed, followed by a second line containing the change due. The PrinterState property is set to FiscalReceiptEnding.
If payment < total, a line containing the description and payment is printed. Because the entire receipt total has not yet been tendered, the PrinterState property is set to FiscalReceiptTotal.
If CapAdditionalLines property is false, then receipt trailer lines, fiscal logotype, and receipt cut are executed after the last total line, whenever the receipt total becomes equal to the payment from the application. Otherwise these lines are printed by calling the EndFiscalReceipt method.
PrintRecTotal is performed synchronously if AsyncMode is false, and asynchronously if AsyncMode is true.
PrintRecTotal may cause a PosControlException to be thrown with one of the following values:
Value |
Description |
Busy |
Cannot perform while output is in progress. (Can be returned only if AsyncMode is false.) |
ExtendedErrorWrongState: |
The printer is not in the FiscalReceipt state. |
ExtendedErrorCoverOpen: |
The printer cover is open. (Can be returned only if AsyncMode is false.) |
ExtendedErrorJournalEmpty: |
The journal station is out of paper. (Can be returned only if AsyncMode is false.) |
ExtendedErrorReceiptEmpty: |
The receipt station is out of paper. (Can be returned only if AsyncMode is false.) |
ExtendedErrorSlipEmpty |
The slip station was specified, but a form is not inserted. (Applies only if AsyncMode is false.) |
ExtendedErrorBadItemAmount: |
One of the following errors occurred:
|
ExtendedErrorBadItemDescription: |
The description is too long or contains a reserved word. (Can be returned only if AsyncMode is false.) |
ExtendedErrorNegativeTotal: |
The total computed by the printer is less than zero. (Can be returned only if AsyncMode is false.) |
ExtendedErrorWordNotAllowed: |
The description contains a reserved word. |
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
FiscalPrinter Class
FiscalPrinter Members
Microsoft.PointOfService Namespace
FiscalPrinter.BeginFiscalReceipt Method
FiscalPrinter.EndFiscalReceipt Method
PredefinedPaymentLines
AmountDecimalPlaces
FiscalPrinter.PrintRecCash Method
PrintRecItem
PrintRecItem
PrintRecItemAdjustment
FiscalPrinter.PrintRecItemAdjustment Method
PrintRecItemFuel
PrintRecItemFuel
PrintRecItemFuelVoid
FiscalPrinter.PrintRecItemFuelVoid Method
FiscalPrinter.PrintRecMessage Method
FiscalPrinter.PrintRecNotPaid Method
PrintRecPackageAdjustment
PrintRecPackageAdjustVoid
PrintRecRefund
FiscalPrinter.PrintRecRefund Method
PrintRecRefundVoid
FiscalPrinter.PrintRecRefundVoid Method
FiscalPrinter.PrintRecSubtotal Method
FiscalPrinter.PrintRecSubtotalAdjustment Method
FiscalPrinter.PrintRecSubtotalAdjustVoid Method
FiscalPrinter.PrintRecTaxId Method
PrintRecVoid