Jump to content

Does metadata from For Each Loop work on a Wrangle node?


Recommended Posts

I'm trying an apparently simple example. If I try to get the For Each iteration on an Attribute Wrangle with something like

f@distance = detail("../foreach_begin1_metadata1", "iteration",0);

it's not grabbing the iteration number.

If I do the exact same thing on an Attribute Create, it works.

Am I forgetting something on VEX, or is the Wrangle node having a problem with this data?

 

Link to comment
Share on other sites

just add a parameter to the wrangle node and use the stamp() or stamps() expression in there ;)

getting an detail attribute should also work just fine, but maybe it works better if you just put:

//

f@distance = float(detail(0, "iteration"));

//

instead,

also you may want to try to put a node inbetween the "begin" node and the wrangle

Link to comment
Share on other sites

Prefix node path with "op:" or use metadata node as a second input:

// Using "op:"-syntax.
detail("op:../foreach_begin1_metadata1", "iteration")
  
// As a second input.
detail(1, "iteration")
i@opinput1_iteration
detail("opinput:1", "iteration")
detail(@OpInput2, "iteration") // Here count starts from 1.

 

  • Like 9
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...