AR10 Viewer - Printer Dialog very slow compared to older versions of AR

Posted by: mike.stinson on 5 February 2018, 3:23 pm EST

    • Post Options:
    • Link

    Posted 5 February 2018, 3:23 pm EST

    I am using ActiveReports-v10.3.9175.0 Viewer. I open an .RDF file then i click on the Printer Icon and the Printer Dialog takes up to 20 seconds to display.

    I have not tried newer versions of AR.

    Thanks in advance for your prompt response.

  • Posted 6 February 2018, 2:56 am EST

    Hello,

    I am unable to replicate the issue at my end. Please refer the attached video. Could you please confirm that is there anything extra are you doing to print the report.

    Thanks,

    Mohit

  • Posted 6 February 2018, 2:56 am EST

  • Posted 6 February 2018, 12:59 pm EST

    Thanks for the video. I have 1 customer with 160 network printers installed. When they click the printer dialog 15-20 seconds. I have another customer with 12 network printers, it takes 40 seconds to get the dialog. We previously came from AR4 .net framework 2 and i can run this viewer, click the dialog and the list pops instantly.

    If you only have a few printers installed its about a 2 second delay however it you test it with older versions of the viewer you will see the older version is much faster

  • Posted 6 February 2018, 1:03 pm EST

    I forgot to mention i reproduced the same behavior in AR12.

  • Posted 6 February 2018, 11:35 pm EST

    Hello,

    Thanks for the information.

    Could you please see if the same problem is reproducible with any other application (except AR) as well.

    Sorry for troubling you again.

    Thanks,

    Mohit

  • Posted 7 February 2018, 9:11 am EST

    I tried other types of documents such as .pdf, .docx as well as printing for Internet Explorer.

    All applications it tested when clicking the printer dialog worked fine. No performance issues.

    I was using Adobe Reader, MS Word, IE and all worked fine.

    There must be something different in that printer dialog that is perhaps checking all the properties on each printer or something like that.

  • Posted 7 February 2018, 9:11 am EST

    I tried other types of documents such as .pdf, .docx as well as printing for Internet Explorer.

    All applications it tested when clicking the printer dialog worked fine. No performance issues.

    I was using Adobe Reader, MS Word, IE and all worked fine.

    There must be something different in that printer dialog that is perhaps checking all the properties on each printer or something like that.

  • Posted 8 February 2018, 2:42 am EST

    Hello,

    Yes, you are right. The latency in print dialog is usually caused when the printer is a network printer or there are multiple printers installed on the machine. For printing, ActiveReports fetches the settings for all the installed printers, hence the delay. If it’s a SectionReport, you can set the PrinterName to “” (empty string) in the Report’s constructor (if it’s a code-based report) or using the report’s object if it’s an rpx.

    Another solution is to use the StandardDialog for printing which can be set using either of the code snippets given below:

    1. Document.Print(GrapeCity.Viewer.Common.PrintingSettings.UseStandardDialog);

    2. Document.Print(GrapeCity.Viewer.Common.PrintingSettings.UsePrintingThread| GrapeCity.Viewer.Common.PrintingSettings.UseStandardDialog);

    Hope it helps.

    Thanks,

    Mohit

  • Posted 8 February 2018, 12:10 pm EST

    Hello,

    Could you please check after using the following code

    
    Dim rpt As New SectionReport ()
                rpt.Document.Load(rdffile)
                rpt.Document.Printer.PrinterName = ""
                rpt.Run()
                viewer1.Document = rpt.Document
    
    

    Sorry for troubling you again.

    Thanks,

    Mohit

  • Posted 8 February 2018, 12:36 pm EST

    No help. Also, i am loading a .RDF file into the Viewer.

  • Posted 9 February 2018, 5:07 am EST

    Hello Mike,

    I can see in your video, you are still using default print option. Please refer the attached sample which shows the printing using Standard print dialog.

    Hope it helps.

    Thanks,

    Mohit

    rpt_Print.zip

  • Posted 9 February 2018, 8:20 am EST

    Thank you. That change fixed the problem.

  • Posted 9 February 2018, 8:21 am EST

    Please help with code changes - i am not seeing a difference in performance

                Report_rpt_m.Document.Load(RDFName_str_p)
                'assign the output document from the report engine to the viewer control
                Viewer_frm_p.arvMain.Document = Report_rpt_m.Document
                'is this the line i should insert to prevent the long printer dialog delay ?
                Viewer_frm_p.arvMain.Document.Printer.PrinterName = ""
    
                'show the form
                Viewer_frm_p.WindowState = FormWindowState.Normal
                Viewer_frm_p.Show()
    
Need extra support?

Upgrade your support plan and get personal unlimited phone support with our customer engagement team

Learn More

Forum Channels