Is it possible to print a report directly without print dialog on asp.net

Is it possible to print a report directly without print dialog on asp.net?

While in "debug mode" it works greate but when we publish the project to IIS the report throws error like this

Comments

  • edited 5:50AM
    Any idea?
  • edited 5:50AM
    nzmhtpgl wrote: »
    Any idea?

    Method #1:

    - call Prepare()
    - call PrintPrepared(printerSettings)


    The only thing you have to find out are the printer settings for the default printer, but this should be quite easy. You find more information in the MSDN library.

    Method #2:

    Just take a look at the reports PrintSettings: You'll find a "ShowDialog" property. Maybe it helps to set this one to false.
  • edited 5:50AM
    if you know the name of your printer the following code works just fine:
    ReportFast.Prepare();
    
    // print report to pdf printer
    ReportFast.PrintSettings.Printer = "PDFCreator";
    ReportFast.PrintSettings.ShowDialog = false;
    ReportFast.Print();
    
  • edited 5:50AM
    Any idea?

    Method #1:
    - call Prepare()
    - call PrintPrepared(printerSettings)

    The only thing you have to find out are the printer settings for the default printer, but this should be quite easy. You find more information in the MSDN library.

    Method #2:

    Just take a look at the reports PrintSettings: You'll find a "ShowDialog" property. Maybe it helps to set this one to false.

    It is possble in desktop applications but not in browser applications (asp.net) bacause of security!
  • edited 5:50AM
    IngoFR wrote: »
    if you know the name of your printer the following code works just fine:
    ReportFast.Prepare();
    
    // print report to pdf printer
    ReportFast.PrintSettings.Printer = "PDFCreator";
    ReportFast.PrintSettings.ShowDialog = false;
    ReportFast.Print();
    


    It is possble in desktop applications but not in browser applications (asp.net) bacause of security!

Leave a Comment

Rich Text Editor. To edit a paragraph's style, hit tab to get to the paragraph menu. From there you will be able to pick one style. Nothing defaults to paragraph. An inline formatting menu will show up when you select text. Hit tab to get into that menu. Some elements, such as rich link embeds, images, loading indicators, and error messages may get inserted into the editor. You may navigate to these using the arrow keys inside of the editor and delete them with the delete or backspace key.