Session Parameters

Session Parameters are documented in Chapter 4 - Application Configuration.

Session parameters are generally defined with application scope and are defined and documented under the Application Configuration options. By default, the link to the Session Parameter management pages is displayed in the Application Configuration drop-down list.

If the ability to specify Organizations is enabled, the session parameter s values may be applied specifically to an organization. In this case, the scope of Session Parameters is closer to User Configuration and the link to the Session Parameter management pages is displayed in the User Configuration drop-down list.


Session Parameters

The Session Parameters screen allows the system administrator to create one or more session variables. The session parameters simply relate values to a name which can be used in an @Session token. They are commonly used in data object filters, but may be used throughout the Ad Hoc instance.

Session variables are part of the .NET Framework and hold a specific value for the duration of the user session. Each session variable is initialized with a specified value when users log in to the application. The value is either the default value set on this page, a value that has been set for the organization, or a value passed to the Ad Hoc instance from a parent application.

Select Session Parameters from the Application Configuration drop-down list to display the Session Parameters configuration page.

Click on the icon to display brief help for the Session Parameters page.

The Add button will display an empty Session Parameter Details dialog.

The Delete button will remove the selected session parameter. Session parameters are selected by clicking on the applicable checkbox.

Click on the Parameter Name column header to sort the list.

Note:

Number and Numeric List session parameters must have a default value.

Note:

The following syntax may be used to reference a session parameter:

@Session.<parameter_name>~ where <parameter_name> must exactly match the session parameter name, including character case.

Adding a Session Parameter

 

To add a session parameter, click on the Add button to open the following dialog:

The Parameter Name attribute is how the session parameter will be referenced throughout the application.

The Type attribute defines one of the parameter types recognized by AgileReports. The Type will be used along with the usage context to determine which session parameters to display to the end user. For example, Text session parameters should not be presented as options in the AgileReports user interface when the context clearly calls for a numeric or date value.

The Types include:


Note: When one of the list types is selected the dialog will be adjusted to allow specification of a list of values as shown below:

Note: If a Date type is selected, the dialog will be adjusted and a date picker control will be displayed as shown below:

The Default Value attribute, in the absence of any over-rides based on Organization or User, will be supplied to the application when the session parameter is resolved during the execution of reports.


Modifying a Session Parameter

The Session Parameters page presents a list of session parameters similar to the following:

The session parameters may be sorted by clicking on the Parameter Name column header.

Three actions are available for each session parameter; Modify Session Parameter, Set by Organization and Set by User.


Selecting the Modify Session Parameter action will present a dialog to capture the new session parameter value. For text and numeric type session parameters, the dialog would appear as:

Adjust the Parameter Name, Type, or Default Value information and click on the OK button to save the information.

Note: Changing the Default Value will change the attribute value for all Organizations and Users that are following the default values.

Note: The change is immediate and may affect the current session. It is not necessary to logout and re-establish the session if the changes are impactful to the current user. Other user sessions are not affected by the changes until the user s login.


Selecting the Set by Organization action will present a page similar to the following:

The Selected Session Parameter defaults to the session parameter that was used to navigate to the page. It is also a convenient option to switch the session focus for the page without having to return to the list of session parameters.

The Default Value and Type of the session parameter are displayed for informational purposes.

A list of organizations is presented in the grid. The grid may be sorted by clicking on either the Organization or Follow Default column headers.

The Restore Default button will set the Parameter Value to the displayed Default Value for all selected Organizations.

The Set Value button will present a dialog to capture a new value and apply the value to all of the selected Organizations.

The Follow Default checkbox indicates whether the parameter value should adopt the Default Value. This also allows the parameter value to be set permanently , meaning that changes to the Default Value will have no impact on the parameter value for the organization, if the Follow Default checkbox is unchecked.

The grayed Parameter Value text boxes are not disabled. The gray is a visual cue that the value is the same as the default value and is expected to follow the default value. That mean that if the default value changes, the organization will automatically pick up the new value.

The Parameter Value may be changed by either typing directly into the text box or selecting the Modify action and providing a new value. The parameter value may also be changed by selecting the Restore Default action.

Click on the Save button to store the session parameter values for the Organization.

Note: The Set by Organization action will not be presented from the Session Parameters page if the AgileReports instance has not been configured to allow the specification of Organizations.


Selecting the Set by User action will present a page similar to the following:

The Selected Session Parameter defaults to the session parameter that was used to navigate to the page. It is also a convenient option to switch the session focus for the page without having to return to the list of session parameters.

The Type attribute identifies the session parameter type; date, number, numeric list, text, or textual list.

The Organization dropdown list is used to filter the user list by their respective organization. The Organization dropdown list is only displayed in the page when the AgileReports instance is configured to allow multiple organizations and when more than one organization exists.

The Default Value reflects the current default value for the session parameter. The actual value may be the original application scope session parameter value or the organization scope parameter value.

The Role dropdown list allows the list of user to be filtered by role.

A list of users is presented in the grid. The grid may be sorted by clicking on either the User or Follow Default column headers.


The Restore Default button will set the Parameter Value to the displayed Default Value for all selected Users.

The Set Value button will present a dialog to capture a new value and apply the value to all of the selected Users.

The Follow Default checkbox indicates whether the parameter value should adopt the Default Value. This also allows the parameter value to be set permanently , meaning that changes to the Default Value will have no impact on the parameter value for the user, if the Follow Default checkbox is unchecked.

The grayed Parameter Value text boxes are not disabled. The gray is a visual cue that the value is the same as the default value and is expected to follow the default value. That mean that if the default value changes, the user will automatically pick up the new value.

The Parameter Value may be changed by either typing directly into the text box or selecting the Modify action and providing a new value. The parameter value may also be changed by selecting the Restore Default action.

Click on the Save button to store the session parameter values for the User.