[2 days left] What’s wrong with your cloud strategy? Learn why multicloud solutions matter with Nimble Storage.Register Now

x
?
Solved

setting a suitable receipt printer for a VB POS application

Posted on 2003-11-17
4
Medium Priority
?
653 Views
Last Modified: 2013-11-18
guys help. hav ma VB POS running on win98, NT n 2000 but cant print receipts directly to an old epson TM-U210D receipt printer i hav. what do i do? som pple tell me i need a windows cable som say another printer, which one? n when i click print button from my program, the old TM-U210D prints garbage. what do i do? or could it b a com port error? but i fixed a new com port (com2). or could it b da cable (must there b one 4 windows). or could it b settings? i don know!

by the way this printer has been used n being used in receipt printing from a DOS based POS we r trying to replace.

o'wise the receipts r printed very well on any other printers with A4 size, but ma problem is i wanna print on a small paper size receipt printer n directly easily just like any othe printer. is tha possible, how?
ps advice, urgent, any quick hlp ll highly appreciate.

eric, programmer
Nairobi
KENYA
erabby411@yahoo.com
0
Comment
Question by:eric-kenya
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
4 Comments
 
LVL 4

Accepted Solution

by:
TomLaw1999 earned 375 total points
ID: 9764187
Have you installed a TM-U210D printer driver on your system for this device.
0
 
LVL 30

Expert Comment

by:nmcdermaid
ID: 9764226
As far as I know, VB just goes through the normal Windows print services, so you should try to get it printing from standard Windows Apps first, such as Notepad and Write.

If it doesn't print from standard windows programs, then you may have better luck in the Hardware newsgroups as it is not a VB specific thing.


Good Luck




0
 

Author Comment

by:eric-kenya
ID: 10190563
COMMENT/CONTRIBUTION
by reading the comments n answers provided n practically trying them, hav came up with an easy way of printing direct to any receipt printer from a VB POS: open, close, requery then open n close the record source then set and select the device from your VB codes procedure. Below is a working sample from my POS (a restaurant billing system) Final Bill Click event:-

cmdFinalBill_Click ()

DataEnvironment1.rsReceipts.Open
DtRptFinBill.Sections("Section7").Controls("lblShiftNum").Caption = frmProcessBills.txtShiftNum.Text
DtRptFinBill.Sections("Section2").Controls("lblRname").Caption = frmMain.txtRname.Text
DtRptFinBill.Sections("Section2").Controls("lblRtel").Caption = frmMain.txtRtel.Text
DtRptFinBill.Sections("Section6").Controls("lblWaiter").Caption = frmProcessBills.txtWTname.Text
DtRptFinBill.Sections("Section7").Controls("lblFinAmount").Caption = frmProcessBills.txtFDamount.Text & ".00"
DtRptFinBill.Sections("Section7").Controls("lblPayMode").Caption = frmProcessBills.txtPayMode.Text
DtRptFinBill.Sections("Section7").Controls("lblDiscAmount").Caption = frmProcessBills.txtDiscAmount.Text & ".00"
DtRptFinBill.Sections("Section7").Controls("lblCash").Caption = frmProcessBills.txtCash.Text & ".00"
DtRptFinBill.Sections("Section7").Controls("lblChange").Caption = frmProcessBills.txtChange.Text & ".00"

DtRptFinBill.Sections("Section7").Controls("lblMemName").Caption = frmProcessBills.txtNameMem.Text
DtRptFinBill.Sections("Section7").Controls("lblMemNo").Caption = frmProcessBills.txtNumMem.Text

DtRptFinBill.Sections("Section7").Controls("lblMemName").Visible = True
DtRptFinBill.Sections("Section7").Controls("lblMemNo").Visible = True

DataEnvironment1.rsReceipts.Requery
DtRptFinBill.Sections("Section7").Controls("lblShiftNum").Caption = frmProcessBills.txtShiftNum.Text
DtRptFinBill.Sections("Section2").Controls("lblRname").Caption = frmMain.txtRname.Text
DtRptFinBill.Sections("Section2").Controls("lblRtel").Caption = frmMain.txtRtel.Text
DtRptFinBill.Sections("Section6").Controls("lblWaiter").Caption = frmProcessBills.txtWTname.Text
DtRptFinBill.Sections("Section7").Controls("lblFinAmount").Caption = frmProcessBills.txtFDamount.Text & ".00"
DtRptFinBill.Sections("Section7").Controls("lblPayMode").Caption = frmProcessBills.txtPayMode.Text
DtRptFinBill.Sections("Section7").Controls("lblDiscAmount").Caption = frmProcessBills.txtDiscAmount.Text & ".00"
DtRptFinBill.Sections("Section7").Controls("lblCash").Caption = frmProcessBills.txtCash.Text & ".00"
DtRptFinBill.Sections("Section7").Controls("lblChange").Caption = frmProcessBills.txtChange.Text & ".00"

DtRptFinBill.Refresh

DataEnvironment1.rsReceipts.Close

'selecting and setting the required receipt printer
Dim X As Printer
For Each X In Printers
'Printer.PaperSize = vbPRPSUser
   If X.DeviceName = "EPSON TM-U210D" Then
     'Set printer as system default.
      Set Printer = X
      DtRptFinBill.PrintReport
      ' Stop looking for a printer.
      Exit For
   End If
Next
MsgBox "sent to printer",vbInformation,"Erix POS Hotbill"

End Sub




Best of luck!

eric,
programmer
Nairobi, Kenya
erabby411@yahoo.com
0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

SSL stands for “Secure Sockets Layer” and an SSL certificate is a critical component to keeping your website safe, secured, and compliant. Any ecommerce website must have an SSL certificate to ensure the safe handling of sensitive information like…
If you need to start windows update installation remotely or as a scheduled task you will find this very helpful.
Get people started with the process of using Access VBA to control Outlook using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Microsoft Outlook. Using automation, an Access applic…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…
Suggested Courses

649 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question