Posted 9 January 2024, 12:02 pm EST
Is it possible to add parameters at runtime for RDL/Page Reports? I can only see it for section reports
Forums Home / ActiveReports / General Discussion
Posted by: bnguyen on 9 January 2024, 12:02 pm EST
Posted 9 January 2024, 12:02 pm EST
Is it possible to add parameters at runtime for RDL/Page Reports? I can only see it for section reports
Posted 10 January 2024, 1:07 am EST
Hi Bryan,
Yes, you can add a parameter at runtime for Page/RDL reports by loading your report into a ‘PageReport’ class object, creating a ‘ReportParameter’ object, and adding the same to the report by using the ‘PageReport.Report.ReportParameters.Add()’ method.
To assign a value to your parameter you can use the ‘PageReport.Document.Parameters[“Parameter1”].CurrentValue’ property.
Please find attached a sample implementing the same.
Regards,
Anand