We know that for a given element, it could be assigned with several variables.
for example, variable ZCR_RULE_TEST has only maintained two variables.
It is a common misunderstanding that an element could only use the variables which are assigned to it in this customizing during the layout design. This is not correct.
See example for above element. Although it has only been assigned with two variables. However in the design time, all variables defined for the content are available for use.
To understand the relationship between variable and element, we must first know one attribute for variable.
When we create a variable, we have to maintain its visibility:
The dialog visibility means the variable must be displayed in the dialog processing. Normally the description of variable will be maintained as the style of question, to guide end user to input accordingly, see example below.
Note: in this example, all variables marked with "Dialog only" or "Dialog and Fill-in Tab" will appear in the tab "Dialog".
And in Document Summary, you could see only the two variables assigned to the element are displayed:
Once you have fnished the value fill and click button "Accept":
And you could see the values are filled in the document:
Summary
1. If a simple variable is marked as "Dialog and fill-in tab", it means this variable is then displayed as a leaf node in the variable tree and could be used in the layout design of any element. This means even if you have not assigned it to a given element, you can still drag this variable to the layout part of that given element. Till now there is no hard relationship between the variable and the given element.
Meanwhile if you also have assigned the variable to the element in customizing, then the variable will be displayed in the fill-in tab of that element, as shown in the example above.
2. If a simple variable has visibility "Fill-in tab only", then it will not be displayed in the Dialog tab. For example I have set ZJERRY_TEST as "Fill-in Tab only"
and it will not be displayed in the Dialog tab any more:
But it still could be consumed in the element design:
So essentially speaking, the assignment of variable to element below could only control whether a variable will appear in the fill-in tab of a given element, but could not controll whether a variable could be consumed in the element layout design.
In order to find out which variables have been maintained to a given element, please query table /IPRO/TELM_VAR with element name for field ELMNTX: