How to pass parameters to Get Dynamic Report

Stimulsoft Reports.JS discussion
Post Reply
harshdeep71
Posts: 1
Joined: Thu Nov 26, 2020 6:12 pm
Location: India

How to pass parameters to Get Dynamic Report

Post by harshdeep71 »

Dear Support,

I am using Angular Report viewer and using the Github example. I wanted to pass the parameter (as show below) to the action GetReport() so that I can use the report accordingly. I wanted to use the dynamic based on the parameter.

Code: Select all

 [HttpPost]
        public IActionResult GetReport(int reportId)
        {
            var report = StiReport.CreateNewReport();
            var appReport = _reportRepository.Get(reportId);
            if (string.IsNullOrEmpty(appReport.ReportDefinition))
            {
                Logger.Error(L("ReportDoesNotAvailable", reportId));
                return BadRequest();
            }
            report.LoadFromString(appReport.ReportDefinition);
            return StiAngularViewer.GetReportResult(this, report);
        }
Thanks
Lech Kulikowski
Posts: 6266
Joined: Tue Mar 20, 2018 5:34 am

Re: How to pass parameters to Get Dynamic Report

Post by Lech Kulikowski »

Hello,

Sorry, maybe we did not exactly understand your question. Could you explain your issue in more detail, which parameters do you need?

Thank you.
Post Reply