Hi,
I cannot see the templates, my best guess is that you want a single XML with multiple "ROAD"s as sub-elements and each ROAD sub-element has multiple vertices.
In XMLTemplater you can nest Sub Templates. Eg:
If you use use in ROOT:
{fme:process-features("ROAD")}
you can use in the ROAD template:
{fme:process-features("GEOMETRY", "COUNTER_2_ATTR", fme:get-attribute("COUNTER_2_ATTR"))}
COUNTER_2_ATTR is the Count Output Attribute that you set in the Counter_2 transformer.
Is it something you wanted to achieve?
It's hard to find a solution unless attributes which the input features have and the XML schema you need to create from them would be clarified. Could you please elaborate the conditions and the requirements specifically?
Hi,
I cannot see the templates, my best guess is that you want a single XML with multiple "ROAD"s as sub-elements and each ROAD sub-element has multiple vertices.
In XMLTemplater you can nest Sub Templates. Eg:
If you use use in ROOT:
{fme:process-features("ROAD")}
you can use in the ROAD template:
{fme:process-features("GEOMETRY", "COUNTER_2_ATTR", fme:get-attribute("COUNTER_2_ATTR"))}
COUNTER_2_ATTR is the Count Output Attribute that you set in the Counter_2 transformer.
Is it something you wanted to achieve?
Thats exactly what i need. It just looks like a matlab function which i can give parameters with it.
Thanks!
Hi,
I cannot see the templates, my best guess is that you want a single XML with multiple "ROAD"s as sub-elements and each ROAD sub-element has multiple vertices.
In XMLTemplater you can nest Sub Templates. Eg:
If you use use in ROOT:
{fme:process-features("ROAD")}
you can use in the ROAD template:
{fme:process-features("GEOMETRY", "COUNTER_2_ATTR", fme:get-attribute("COUNTER_2_ATTR"))}
COUNTER_2_ATTR is the Count Output Attribute that you set in the Counter_2 transformer.
Is it something you wanted to achieve?
Can you also show me where and how i have to define the variable "Counter_2_ATTR" ?
Is that like:
Definition:
COUNTER_ROAD := @Count("road")
give the variable like a parameter to my subtemplate "GEOMETRY":
{fme:process-features("GEOMETRY","COUNTER_ROAD",fme:get-attribute("COUNTER_ROAD")}
But i think i can't declare and use the variable in the same subtemplate "ROAD". So that means that i should split the declaration and the hand over to "GEOMETRY" is that right ?
Can you also show me where and how i have to define the variable "Counter_2_ATTR" ?
Is that like:
Definition:
COUNTER_ROAD := @Count("road")
give the variable like a parameter to my subtemplate "GEOMETRY":
{fme:process-features("GEOMETRY","COUNTER_ROAD",fme:get-attribute("COUNTER_ROAD")}
But i think i can't declare and use the variable in the same subtemplate "ROAD". So that means that i should split the declaration and the hand over to "GEOMETRY" is that right ?
Please read @revesz's answer more carefully.
"COUNTER_2_ATTR is the Count Output Attribute that you set in the Counter_2 transformer."