Error in Subreports?

Posted by: rab on 4 August 2017, 3:07 pm EST

  • Posted 4 August 2017, 3:07 pm EST

    I have 2 reports in a DLL. One w/o subreports works, the one with 2 subreports does not work and is generating the following errors. Both work fine in design.



    The error is:

    [The VB Application identified by the event source logged this Application SoilDll: Thread ID: 2564 ,Logged: Error Number: -2147220504 ReportServer: An Unknown Error occured.

    [ExtendedInfo: RunReport Failed: Desc:ActiveReports PDF export DLL error

    Pages collection contains 0 pages. Export Fails., Source:ActiveReportsPDFExport.ARExportPDF. The activity that caused the failure was Exporting PDF.]

    Then,

    [The VB Application identified by the event source logged this Application SoilDll: Thread ID: 2584 ,Logged: Error Number: -2147220504 ReportServer: An Unknown Error occured.]

    [ExtendedInfo: RunReport Failed: Desc:Pages.Save method failed. Pages Collection is empty., Source:Canvas Object. The activity that caused the failure was RunReport - Report has run.]

    after testing by saving to RDF.



    I am setting the subreports in ReportStart():

    Set srpt_SoilCts.object = New SoilCts_subrpt

    srpt_SoilCts.object.DataControl2.Source = "Select * from qrySoilCts where projectid = " & txtProjectID.Text & " order by ccorder "

    Set srpt_SoilProctors.object = New SoilProctors_subrpt

    srpt_SoilProctors.object.DataControl3.Source = "Select * from qrySoilProctors where projectid = " & txtProjectID.Text & " and testdate = #" & txtTestDate.Text & "# order by proctno "



    and unloading these in ReportEnd().



    I have omitted the subreports and it will work. I suspect the subreports aren't getting the connectionstring, but don't know how to pass that to them.



    Thanks





  • Replied 4 August 2017, 3:07 pm EST

    Rab,

    Thank you for your question. Would it be possible for you to localize this behavior in a small running sample app so that i can clearly see the behavior you are encountering in a testing environment?

    Please ensure you are using the latest build available (1309). You can find the update here.

    Also, if you would like to pass data such as a connection string to a sub report you can create a public property in the sub report so that you can set it before the report is run. Please see the unbound subreports walkthrough here for an example of creating and using properties in reports.

    Thanks,
    Eric


Need extra support?

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

Learn More

Forum Channels