question

Rohit Bhardwaj avatar image
Rohit Bhardwaj asked ·

StaticBillPrintJob doesn't print the bill

Hi,


I want to print the order bill irrespective of the payment initiated or not. I tried using the below code,

PrintJob pj = new StaticBillPrintJob.Builder().order(order).build();
pj.print(context, CloverAccount.getAccount(context));

But this doesn't print the bill. I get a toast message as "Bill is sent to Printer" but after that I get an error notification from printer app.

I also tried using StaticReceiptPrintJob and StaticOrderPrintJob instead of StaticBillPrintJob but it didn't work either.

Please advice. Thank you.

OrdersPrint
14 comments
10 |2000 characters needed characters left characters exceeded

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Is this a devkit? If so, please dump the device logs (adb logcat) after the problem happens and provide them here.

0 Likes 0 · ·
Rohit Bhardwaj avatar image Rohit Bhardwaj David Marginian ♦♦ ·

I use Android Emulator for testing the application. For testing the print I have to upload the app on Sandbox environment and test it using clover station 2018. I cannot get logcat this way. The command is sent to the printer but the printer doesn't print the bill, instead it throws an error and the print job is queued in the list.

0 Likes 0 · ·

You have a Clover Station 2018 devkit? You can get logcat from a Station 2018 devkit if you attach the debug cable to it. See photo at https://community.clover.com/questions/21481/connect-clover-station2018-dev-kit-to-a-laptop-adb.html

1 Like 1 · ·
Show more comments
Show more comments

0 Answers

· Write an Answer

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Welcome to the
Clover Developer Community