Print selected list view items

Does anyone has experience with printing out selected list view items as separate documents. I know I can hit print and save it as a pdf but I would rather select the correct printer and have the selected items separately printed out with the right print format.

Same thing would be great for child table values (each row as a separate page/selected rows as separate documents).

I’m a bit confused by your request. It seems you should be able to achieve your goal by going to the document list, select the documents by checking the select box, the go to actions > print. This will allow you to send all selected documents to the same printer.

If i do this, I see this dialog:

I am not sure where I can select the printer and how to print them separately. Any idea?

Hii @RSA

When you click on print button in this dialog, It make PDF in background & generate PDF File, then you can print it to your Printer, also that save in file in Frappe

I am using a print format that seems to not align with how the pdf files are created.

.label-content { writing-mode: vertical-rl; /* Right to Left */ text-orientation: mixed; /* Mixed orientation for alphanumeric characters */ transform: rotate(180deg); /* Optional: Rotates the text to ensure it reads from top to bottom */ font-size: 15px; /* Adjust font size as necessary for the label */ white-space: nowrap; /* Prevents text from wrapping to the next line */ position: absolute; /* Positions the element absolutely within its closest positioned ancestor */ left: 30; /* Aligns the element to the left side */ top: 30; /* Aligns the element to the top, optional based on your layout needs */ } .field { margin-bottom: 5px; /* Adds space between each field */ }
Nr.:
...

The problem is that the text isn’t being rotated properly when creating a pdf first. If I am individually printing out the documents, the “coded” rotation is being applied. That’s why I was asking to directly target the printer rather than having a pdf first.

You can usually achieve this by selecting items, choosing your printer, and adjusting the settings for each to get the right format. It might need some setup in your software.

What happens after selecting (letter Head, Print Format, and Page Size)? If you don’t get a generated PDF ready to print, it’s likely an issue with your hosts file. For wkhtmltox to work, it needs an entry in /etc/hosts that match the domain name used for your site.

Like:

127.0.0.1       localhost
127.0.1.1       erp.local my.secondsite.net any.otherdomains.com

I know, it is all set up correctly and I get a PDF file but it isn’t aligned vertically, hence the question for directly printing the selected items. I will write some python code and attach it to a button to trigger the preconfigured printing dialog. That’s probably the easiest way to do it since vertical printing and wkhtmltopdf dont seem to get along too well

I see. I create a unique print format when I need to print to PDF. I’ve never been able to get docTypes to print the same using “print to PDF” vs direct printing.