Number of children elements in xml

I am pretty new on touch designer,
i tried to display sentence loaded from a xml.
i am almost done except, i can’t not get the number of a children in a xml that i need to loop correctly.
i use this python code,

var = op('xml1').numRows;
op('constant_increment1').par.value0 = var -1;

but i can’t use a chop execute cause it ask me for a only for text
How to use excute on xml op ?
thnaks for your help

execute DAT?

Not sure what you’re trying to do exactly. Posting a tox might help

when i plug a execute dat on a xml1 op
I got a error message, must be text only

Ah, that wiring is to fill the actual text of the datexec. Create a new datexec then drag your xml1 DAT into the “DAT” parameter (or “DATs” parameter in later versions). You can then react to changes in xml1 if that is what you want to do.

Thanks,
it’s work perfectly

1 Like