Print pdf file

Hey! Can someone help me printing a pdf file without prior downloading it on the user’s pc? I wish I could directly open the print dialogue

That’s not possible.

You could use this component but the PDF will be downloaded anyway

PrintJS manages to print the file without downloading (or at least visible downloading): - I hoped Vaadin has something built in for that :sweat_smile:

This could use this with Vaadin

printjs looks interesting, for this decades old web app ux issue. It looks like it don’t work in Safari though.

BTW. If your app happens to run in the old fashion way on a server at your office, and your users are there as well, you can print it from your Vaadin app. Create the PDF to some location on the server and then use lp command to send it to your office printer.

Maybe directly printing a PDF may confuse the users as it is expected that the pdf opens in a pdf viewer (either in the browser or in acrobat).
lp will only work if the printers are correctly configured on the linux server

Yeah, I would be confused as I’m so used to this “web way of printing” :grin: