User-1330468790 posted
Hi, Dhoni,
If I understand right, are you trying to access the printer of the client side since printing is a client-side activity.
You can not access CLIENT side printer from the SERVER side. If this was possible, it would risk that the harmful website link to your printer and print garbage to you.
I think you are transferring code from winform to webform.
Windows forms:
They are client side so that they have the access to local printers on the client.
Web forms:
The code are executed on the SERVER that a print call will be executed from the SERVER machine.
To control the printing activity, the server pass the page with javascript function window.print(), which could be bound to a button event inside the page.
That way, the client side could set the property of the printing and complete the printing stuff.
Hope this can help you.
Best regards,
Sean