How to output a List in {0} in C#

image
i am coding in vs,and need to output a list in{0} instead of{0:0}(like image above…)
i know we can use flatten near the output gripper…but i just want do that in code.
Thank you for helping!

Hi
Try the datatree’s SimplifyPaths() method?Does this help?

2 Likes

thank you Naruto
but i need keep the input kind as “item”(yours is datatree)
like this:


how to change the code to output {0} instead of {0:0}?
Thank you very much!

You can only choose your output tree paths if you set the tree yourself. Since your input is {0;0}, your output will be {0;0}, as the input is used to figure out the appropriate output layout.

1 Like