In This Topic
To perform data binding in report parameters, the steps are as follows:
- Run FlexReportDesigner.exe application.
- Create a new report. Bind it to a data source, which is the Main data source. The report opens in the Design mode.
- Click the Data tab.
- Right-click Data Sources and select Add Data Source The Data Sources dialog box appears.
- Select a Data Source, say DataSource1, to create a new data source and set Connection, Data provider, Connection string, etc.
- You can rename DataSource1 from the Properties window by setting Name property. In our case, we have set Name to dsCategories.
- Add a parameter by right-clicking Parameters and then selecting Add Parameter.
- From the Properties window, click the ellipsis button next to AllowedValuesDefinition. The AllowedValuesDefinition Editor dialog box appears.
- Select the From Data Source radio button and then select Data Source, Label, and Value for binding the data source to the parameter as shown. Click OK.
- From the Properties window, set the DataType to a value that is same as the data type of Value in the AllowedValuesDefinition Editor. In our case, DataType is set to Integer since Value=CategoryID is integer.