How I make iterative chsop() paths for multiparm use?

   807   2   1
User Avatar
Member
6 posts
Joined: June 2019
Offline
Hello!

I'm trying to use an object merge with a multiparm. I have a for loop that iterates as many multiparm instances are set. The multiparm has an object field for the user to select an object. That object is then merged into the for loop based on the current iteration.

For something other than an Operator Path, my expression would look something like this:
chs(strcat(("../param_interface/layer_name"), detail(0,"iteration",0)+1))

If I try to use something similar to that for the chsop(), I get an error. This is the exact expression I tried:
`strcat(chsop("../parameters/oper_path_"),detail("../loop_meta",iteration,0))`
Warning: Invalid sop specified: "1".
Bad parameter reference: "../parameters/oper_path_" in parameter/obj/box1/object_merge1/objpath1.

Here's a picture of my example:


So I wasn't 100% sure whether or not the problem was with the detail node, so I* tried an example without the detail half of the expression and just used "1":
`strcat(chsop("../parameters/oper_path_"),"1")`

That also returned an error. So far the only thing that works is no strcat() to build the channel reference.
`chsop("../parameters/oper_path_1")`

Am I missing something obvious? Please help!

Attachments:
multiparm_operatorpath.hiplc (81.9 KB)

User Avatar
Member
6 posts
Joined: June 2019
Offline
Hey, so I found out the solution, just had the strcat() in the wrong place.

The expression should look like this:

`chsop(strcat("../parameter_sop/parameter",detail("../loop_metadata", "iteration", 0)+1))`
User Avatar
Member
206 posts
Joined: Jan. 2016
Offline
@bbstrung great, thank you very much for posting the solution!
  • Quick Links