ssql = "Select posprinter from [Settings] "
Ocom.CommandText = ssql
Set orec = Ocom.Execute
Dim prnPrinter As Printer
For Each prnPrinter In Printers
If prnPrinter.DeviceName = orec!posprinter Then
Set Printer = prnPrinter
Exit For
End If
Next
'Open Till Draw
Printer.Print "A"
Printer.Font.Size = 9.5
Printer.FontName = "Arial"
Printer.Font.Size = 12
Printer.Font.Bold = True
Set orec = New Recordset
ssql = "Select * from [Company Info]"
Ocom.CommandText = ssql
Set orec = Ocom.Execute
Printer.Print orec!Coname
Printer.Font.Size = 9.5
Printer.FontName = "FontA1x1"
Printer.Print orec!Coline2
Printer.Print orec!coaddress1
Printer.Print orec!coaddress2
Printer.Print orec!coaddress3 + "," + orec!coaddress4
Printer.Print "Tel: " + orec!cophoneno
Printer.Print "Vat Reg: " + orec!coregno
Printer.Font.Size = 19
Printer.FontName = "FontA1x2"
Printer.Print " "
A$ = "TAX INVOICE"
Printer.Print A$
Printer.Font.Size = 9.5
Printer.Font.Size = 9.5
'Printer.FontName = "FontA1x1"
Printer.FontName = "courier new"
Printer.Font.Bold = True
Printer.Print "Customer : " & txtCustomerName
Printer.Print "Date : " & lblDate
Printer.Print "Time : " & lblTime
Printer.Print "Sales Person : " & lblUser
Printer.Print "Slip No : " & InvoiceId
Printer.Print "-----------------------------------------" 'LF
For Each Lst In FrmPOS.lstvInvoice.ListItems
Printer.Print Lst.SubItems(1) & " "
Printer.Print Format(Lst.SubItems(2), "#####0") & " "
Printer.Print Lst.SubItems(4) & " " & Lst.SubItems(10)
Next
Printer.Font.Size = 9.5
Printer.FontName = "Courier New"
'Printer.FontName = "FontA1x1"
Printer.Print "-----------------------------------------" 'LF
Printer.Font.Size = 10
Printer.FontName = "Arial"
Printer.Font.Bold = True
Printer.Print "Total :" + FormatNumber(txtTotal, 2)
Printer.Print "Cash :" + FormatNumber(txtTendered, 2)
Printer.Print "Change :" + FormatNumber(txtChange, 2)
Printer.Font.Size = 9.5
'Printer.FontName = "FontA1x1"
Printer.FontName = "Courier New"
Printer.Font.Bold = True
Printer.Print "Thank you for your Support"
Printer.Print "Visit us: www.distinctiv.net"
Printer.Print "KEEP THIS TILL SLIP AS PROOF OF PURCHASE"
Printer.Print ""
Printer.Print ""
Printer.Print ""
Printer.Print ""
Printer.Print ""
Printer.EndDoc
MsgBox "Please Remove Change and Close Till Draw"