want to create web api for render flex report and export to HTML String

Posted by: angulardev19 on 6 February 2019, 5:47 pm EST

  • Posted 6 February 2019, 5:47 pm EST

    we want to create rest web api for render flex report and output we need Html String we done code as below but not working . please guide us

     public string GetHTMLReport()
    {
    C1FlexReport c1FlexReport1 = new C1FlexReport();
    c1FlexReport1.Load("ReportsSource/test.flxr", "CrystalReport1");

    C1.Win.C1Document.Export.HtmlExportProvider filter = new C1.Win.C1Document.Export.HtmlExportProvider();
    var export= filter.NewExporter();


    c1FlexReport1.RenderToFilter(filter.NewExporter());

    return filter.ToString();
    }
  • Replied 8 February 2019, 5:10 am EST

    Hi,
    We are investigating on this and let you know as we get an update on this.

    ~Manish
  • Replied 10 February 2019, 10:49 pm EST

    Hello,
    You may direct export the FlexReport to HTML format usign C1 WebAPI with ReportViewer (either Wijmo/MVC/MVC Core).
    For reference, please refer to the following demo samples:
    https://demos.componentone.com/aspnet/webapiexplorer/
    https://demos.componentone.com/aspnet/reportviewer101

    In case you have difference use-case, please let us know.

    ~Manish
Need extra support?

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

Learn More

Forum Channels