How to send file to network printer
Question

Hello,

I need implement a solution (Traditional Web or Reactive) that receives information from another system and in this solution create a file and print directly (without downloading the file). 

Steps of the global solution:

1) The other system call the print action, then sends the information to the Outsystems solution.
2) The Outsystems solution receives the information and create a file.
3) Finally, the Outsystems solution send the file for network printing.

How to send file to network printer?
I tried de forge component "Print PDF file by Network Printer" but it didn't work.

Is there any other solution? I need help with this topic.


Thanks.

Best Regards,

Walter Martins


Champion

Hi Walter,
Why don't you try this:

https://printjs.crabbly.com/

Hope it helps,

Assif

Hi assif_tiger,

Thanks for your reply. But I don't think it works for my scenario. The printjs open window.print. The scenario is to send it directly to the printer without opening any more windows or downloading the file.

Best Regards,

Walter Martins

mvp_badge
MVP

Hi Walter,

You cannot do this client-side. That is, there's no way to print anything from your browser, not even via JavaScript, without the browser first invoking the print pop-up. That's a security measure, so malicious websites can't print something without your permission. So any solution you need must print via the server. However, since that's likely a cloud server not connected to your internal network (unless you use VPN), which is the likely cause that the "Print PDF file by Network printer" component doesn't work.

So basically you want something that's not technically feasible, unfortunately.

Hi Kilian,

Thanks for your reply.

Oh, no! Bad news! :)

I will then have to find another type of solution.

Thanks.


Best Regards,

Walter Martins

mvp_badge
MVP

Yeah, it sucks from a corporate point of view, but from a security point of view it makes sense. What you could try to set-up is indeed something via VPN, or have some non-OutSystems component run on your network with access from the outside world (but secured of course) that can pass print requests to a network printer, but it'll be messy.

Community GuidelinesBe kind and respectful, give credit to the original source of content, and search for duplicates before posting.