Printing from ASP.NET

Discussion in 'ASP .Net' started by Igor, Jul 9, 2007.

  1. Igor

    Igor Guest

    Can I print to POS printer (printer for billing reports, bus tickets etc.)
    from aplication? I need to print ticket, then patrial cut and full
    paper cut. Can I do this from page and how?
    Igor, Jul 9, 2007
    1. Advertisements

  2. Eliyahu Goldin, Jul 9, 2007
    1. Advertisements

  3. Is the printer connected to the client machine or on the network...?
    Mark Rae [MVP], Jul 9, 2007
  4. Igor

    Igor Guest

    It is on client but I can connect these printers to the network. But maybe application will be on external web server. Do I need to put it on
    internal web server in the company (in the LAN or VPN network)?
    Igor, Jul 9, 2007
  5. The thing to understand here is that ASP.NET cannot natively interact with
    the client machine, or any peripherals attached to it...

    Therefore, you have several possible solutions:

    1) You attach the printer to the network instead - however, not much good if
    the printer is not reasonably close to the person doing the printing...

    2) You build, sign and deploy an ActiveX control to do the local printing.
    This will need very careful management, as you will almost certainly need to
    modify your local security settings etc. Trying to deploy this on the public
    Internet is a total waste of time - don't even bother...

    3) You create separate "print" aspx pages which contain only the information
    you want to be printed. You may have seen something similar when e.g. you
    have bought an airline ticket and you are given the option to print it -
    however, this will be a manual process for the client.

    4) You create PDF documents of the printouts - however, these will still
    need to be printed manually...

    5) You don't even try to make ASP.NET do the printing. Instead, ASP.NET
    simply adds print "jobs" to a print "queue", maybe in a database, and you
    write a Windows service which will poll this print queue at regular
    intervals and do the printing...
    Mark Rae [MVP], Jul 9, 2007
  6. Igor

    J Fine Guest

    I have exact same needs -- print to ticket printer from page. Printer can be seen on the network from the client. It's possible to make it seen by the server I suppose, but I would rather just send the print job from the client. reason being is that we are already using mead corp print control to suppress print dialog from web page. So that brings me back to somehow sending raw printer commands to the ticket printer???
    J Fine, Jul 10, 2007
  7. can't you use client-side javascript to access the Print item from the main
    menu of the browser??
    Harold Demure, Jul 11, 2007
    1. Advertisements

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.