You can define context variables for various tasks. Context variables make entering parameter values easy for users. For example, you can create context variables for dates such as today, tomorrow and this year. Users can select such relative values when running a report, instead of having to select exact dates from a displayed calendar.
Context variables can be assigned to a context group and a data type can be specified for each group.
Standard Settings
Five context variables are predelivered in the system. You can modify these and also create new ones.
Proceed as follows:
In transaction SPRO open the SAP Reference IMG and navigate to: and click the Activity icon.
Choose New Entries to define a new context group
Field |
Description |
---|---|
Context Group |
Enter a name for the context group. |
Context Group Description |
Enter the name of the time point or data change event. |
Value Type |
Select the data type for the context group. |
Save your settings.
Proceed as follows
In transaction SPRO open the SAP Reference IMG and navigate to: and click the Activity icon.
In the Manage Context Groups view, select a context group and double-click Manage Context Variables on the dialog structure in the left menu. The page lists all context variables that have been defined for the group.
Choose New Entries to create a new variable.
Field |
Description |
---|---|
Context Variable |
Specify the technical name for the context variable to map it to an RFC destination. |
Context Variable Description |
Enter a description for the context variable. |
Control Type |
Select Parameter if the variable refers to specific values (for example, a date). Select Select-Options if the variable refers to relative values (for example, a date range). |
Save your settings.
Proceed as follows
In transaction SPRO open the SAP Reference IMG and navigate to: and click the Activity icon.
In the Manage Context Variables view, select a context variable and double-click Enable Context Variables on the dialog structure in the left menu. The page lists the SAP System Alias that the context variable has been mapped to.
Choose New Entries to define a new system.
Field |
Description |
---|---|
SAP System Alias |
Select the SAP System Alias of the system to locate the class. |
Class |
Select the class name. |
Save your settings.