can't get

Posted by: progame-dd on 4 August 2017, 3:02 pm EST

  • Posted 4 August 2017, 3:02 pm EST

    <P><U>Viewer.PrintReport bShowPrinterDialog</U></P>
    <P>when i print some reports continues to pdf printer, only the first printing can get correct, others is 0.</P>
    <P>after i add code behide it:</P>
    <P><U>Viewer.PrintReport bShowPrinterDialog</U></P>
    <P>so i can get the right pagecount.</P>
    <P>if i print them to office image writer printer, it's ok.</P>
  • Replied 4 August 2017, 3:02 pm EST

    Hello,<br><br>Could you please detail how do you call PrintReport(bDisplayDialog As Boolean) method exactly? Do you pass True or False value?

    <span class="txt2">If you want to print the report to PDF you may want to  take a look at the following KB article on how to print directly to the printer:<b><br></b></span><br><br>You will need to specify the name of the
    printer device before you print:<br>Dim rpt As ActiveReport1<br>Set rpt = New ActiveReport1<br>rpt.Printer.DeviceName = "<NAME OF PDF PRINTER DEVICE"<br>rpt.PrintReport False<br><br><br>How do you get the Pages.Count property? <br><br>Is it possible to post a code sample here? <br>
  • Replied 4 August 2017, 3:02 pm EST

    <P>we need save report as rdf binary stream:</P>
    <P>so we must use viewer to print report</P>
    <P>bShowPrintDialog is boolean value</P>
  • Replied 4 August 2017, 3:02 pm EST

    <P>if i print a report, then click button to print the next, it works fine. but if i let it print many reports at one time, only the first printing can get the right pages.count value. </P>
    <P>but select "Microsoft Office Document Image Writer" is ok, i guess because printing is broken when i save the image file.</P>
    <P>and i add "Doevents" after print also can get the right value.</P>
Need extra support?

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

Learn More

Forum Channels