How to Show or Hide a Tablix Column Using a Parameter in Bold Reports
In Bold Reports Report Designer, you can show or hide a Tablix column at run time by setting an expression on the column’s Visible property using a multi-value parameter. Readers choose which columns to display by selecting values when they run the report.
Applies to: Bold Reports Report Designer · RDL reports
When to use this
Use this when a report contains many columns and different readers need different subsets of information. A multi-value parameter lets each reader select only the columns they need without requiring separate reports.
Steps
-
Create a report with a Tablix and add a multi-value parameter. Configure the available values of the parameter with the names of the columns you want readers to show or hide.
-
Select the Tablix, then switch the Grouping panel to Advanced mode.
-
Select the corresponding static member in the Column Groups hierarchy, then open the expression builder for its Visible property in the properties panel.
-
Enter an exact match expression checking if the column value is selected in the parameter array:
=IIf(Array.IndexOf(Parameters!Parameter.Value, "Column") >= 0, True, False)Parameters!Parameter.Valuerepresents the array of values selected in your multi-value parameter."Column"is the exact value defined in the parameter’s available values for this specific column.Array.IndexOf(...) >= 0checks for an exact match, preventing partial matches where one column name is a substring of another (such as “Sales” inside “SalesRegion”).- When the column name is in the selected values, the Visible expression evaluates to
Trueso the column displays; otherwise it evaluates toFalseto hide it.
-
Repeat steps 3 and 4 for each column in the Tablix, replacing
"Column"with the corresponding column identifier. -
Preview and run the report. Select column values in the parameter dropdown to show those columns, or deselect them to hide them.
Sample report
Download the sample report: Column-By-MultivalueParameter.rdl