RDL/Page report questions - data transferring, etc

Posted by: mgrove on 25 April 2019, 2:14 am EST

    • Post Options:
    • Link

    Posted 25 April 2019, 2:14 am EST

    Configuration/setup info:

    • Windows 10
    • Visual Studio 2017
    • ActiveReports 13 13.0.15823.0
    • C#
    • RDL/page reports

    Process goal:

    • Load data into local dataset variable
    • Manipulate data
    • Load report and insert dataset into report
    • Run the report
    • Save results of report to a file
    • Load results to different computer
    • Display report in viewer

    Question(s):

    • An RDL/page report with a master report and subreports
      • Is it possible to run the report, save the report WITH DATA and load the report on another computer in a viewer?
      • Would the master report need to be present on the other computer?
      • Would each and every subreport need to be present on the other computer?
        • If so, would each subreport need to be saved as well and transported to the other computer?

    There are other parts to this, but the follow-up questions will depend upon response from the above questions.

    Thanks!

    Michael

  • Posted 26 April 2019, 1:40 am EST

    Hello Michael,

    Hello,

    It is not possible to save the report with data and run the report to another computer. Also, master report and all subreports should be present in another system.

    As per workaround, You can convert the RDL report to RDF using the following line of code:

    
     GrapeCity.ActiveReports.PageReport pr = new GrapeCity.ActiveReports.PageReport(new System.IO.FileInfo("../../PageReport1.rdlx"));
    System.IO.DirectoryInfo outputDirectory = new System.IO.DirectoryInfo(@"C:\MyRDF");
    outputDirectory.Create();
    
                GrapeCity.ActiveReports.Export.Rdf.RdfRenderingExtension re = new GrapeCity.ActiveReports.Export.Rdf.RdfRenderingExtension();
                GrapeCity.ActiveReports.Export.Rdf.Settings s = new GrapeCity.ActiveReports.Export.Rdf.Settings();
    GrapeCity.ActiveReports.Rendering.IO.FileStreamProvider fs= new GrapeCity.ActiveReports.Rendering.IO.FileStreamProvider(outputDirectory, System.IO.Path.GetFileNameWithoutExtension(outputDirectory.Name));
                pr.Document.Render(re,fs,s);
    
    
    

    And use the generated document in another computer using the “SectionDocument” and view the document in WinViewer. Also, you do not need to save the master report and subreport if you are using this workaround.

    Hope it clarifies.

    Thanks.

Need extra support?

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

Learn More

Forum Channels