String from Object via codeblock

Hey guys, Is there a way to use the String from Object in the Code Block?

I want to create something like this (see img) but i m trying to find tha way how to write it only via codeblock

line1 = Elements.Element.GetCategory(e1);
mask = line1 == “Ducts” ? true : false;
filtered = List.FilterByBoolMask(line1,mask);
x = filtered[“in”];
y = filtered[“out”];

So much thanks for any help

Have you tried Node To Code?
Select some nodes, richt click on the canvas and select Node to Code.

that’s just my question, when you try to use Node To Code “string from object” doesn’t change
see img:img002

Yeah this one doesn’t node to code.

Try joining the item with another string using a + operator and a string. Note that the string can be empty (“”).


Hey Jacob, thank you! joining with another string works!

1 Like

@martin.biras. Can you please share the screenshot?
Thank you!