Creating Parameters
- 3 minutes to read
This topic explains how to create a new dashboard parameter and specify its settings.
To create a dashboard parameter in the Web Dashboard, perform the following steps.
- Invoke the dashboard menu and select Parameters.
In the Parameter List, click the Add New Parameter button. The following settings will be displayed for the created parameter.
Specify the following parameter’s settings.
Settings
Description
Name
Specifies the parameter name.
Description
Specifies the parameter’s description displayed to an end-user.
The parameter’s description is the value displayed in the Parameter Name column of the Dashboard Parameters dialog.
Visible
Specifies whether the parameter is visible in the Dashboard Parameters dialog.
Allow Null
Specifies whether a null value can be passed as a parameter value.
Allow Multiselect
Specifies whether multi-selection is enabled for the current parameter.
Select All Values
Specifies whether all parameter values should be selected in the initial state of the Dashboard Viewer.
Note that this option is in effect when Allow Multiselect is set to true.
Type
Specifies the parameter type.
Default Value
Specifies the default parameter’s value.
Look-Up Settings
Specifies the parameter’s look-up editor settings. To learn more, see the next step.
Depending on the selected Look-up Settings option, you need to specify the following settings.
Look-up Settings
Description
No Look-Up
An end-user will specify the required parameter value manually in the Dashboard Parameters dialog.
Static List
An end-user will select a parameter value defined in a static list. To add predefined parameter values, use the + button.
Dynamic List
An end-user will select a parameter value defined in a data source. To provide access to data source values, specify the following options.
- First, select the required Data Source from the list of available data sources. For SQL or Entity Framework data sources, select the required Data Member that specifies the query/data member from the selected Data Source.
- Then, specify data members for the dashboard parameter’s value and display name using Value Member and Display Member, respectively.
- If necessary, specify the data member used to sort parameter values using the Sort By option. The Sort Order specifies the required sort order.
Tip
To specify the parameter’s value in code at runtime, handle the SetInitialDashboardState event. The value will be displayed in the Dashboard Parameters dialog and can be changed by the end-user. To change the parameter value before it is passed to a data query, to validate the user value and modify it, handle the CustomParameters event.