Imported from previous forum
[ original email was from Mohamed Riadh Trad - riadh.trad@gltrade.com ]
Hi,
I have a question concerning the scope of a dictionary :suppose that we have 3 templates:
-temp1 : with a template ref to another template :
-temp2: with a template ref to another template :
-temp3:
-temp4: with a template ref to another template :
for temp3, there is no dictionary attribute, does it mean that this template use a global dictionary???
also, temp1 and temp4 use a ref to temp3 does it mean that the fields in tempHeader appear in the Book and Book2 dictionaries as different entries updating them according to which template we are using?
regards,
Riadh
Yes, the fields of tempHeader uses the global dictionary. It does so even when it is included from templates using other dictionaries. The dictionary property has lexical scope, that is, it is only applied to syntactical descendants (and the element itself) of the element holding the dictionary attribute.
/David
Hi,
I have a question concerning the scope of a dictionary :suppose that we have 3 templates: -temp1 : <template name="temp1" id="999" dictionary="Book"> with a template ref to another template : <templateRef name="tempHeader" />-temp2: with a
template ref to another template :-temp3:
-temp4: with a
template ref to another template :for temp3, there is no dictionary attribute, does it mean that this
template use a global dictionary???also, temp1 and temp4 use a ref to temp3 does it mean that the fields in
tempHeader appear in the Book and Book2 dictionaries as different
entries updating them according to which template we are using?regards,
Riadh