Mandatory Parameters in Bold Reports
Bold Reports allows you to set mandatory parameters for your reports. Mandatory parameters are parameters that must be passed for the report to render. If a mandatory parameter is not passed, the information will not render. The required parameters will be denoted by an asterisk (*) at the end. It can help reduce the number of errors that users make when running reports by ensuring they pass values for all mandatory parameters.
To set mandatory parameters in Bold Reports, you need to do the following:
- Create a new report with the parameters you want to use.
- Click on the grey area in your report and navigate to custom properties in the properties panel.
- Add the following custom property:
- ShowRequiredFieldIndicator: Set this property to true to enable the mandatory parameter indicator(*).
- ShowRequiredFieldIndicator: Set this property to true to enable the mandatory parameter indicator(*).
The user must pass values for all the Mandatory parameters to render the report. The ability to set the Mandatory Parameters feature was introduced in the BoldReports version 5.1.28. Ensure you have upgraded your Nuget packages and scripts to this version or later to access this feature.