Edit all elements of the list with Element.SetParameterByName

revit

#1

Hello :slight_smile:

I am an absolute dynamo newcomer and have a beginner question
Unfortunately, I found in Dynamoprimer and here in the forum nothing about my problem.
I would like to fill the parameter Element.SetParameterByName.
The value is always written only in the top element of the input list, but I will bring in all the elements
what do I have to change?


#2

Does it concern only a single type of parameter as well?


#3

Can you upload file or picture…?


#4

Yes, it does


#5

set lacing to longest on the set parameter node


#6

@Marcel_Rijsmus wow so a simple solution :smiley:
Many Thanks


#7

Then maybe try to put a transpose before the line goes into the element input or value input…
Edit: maybe flatten them?


#8

in the code block (the one with “Element”) remove the Braces
it should be:
“Element”;


#9

Yeah, I think that’d be the simplest solution, I didn’t notice that.


#10

Try also my solution
normaly we don’t use Braces in this way


#11

I also think it’s important to understand why @Nico_Stegeman’s solution works. I think that’s actually necessary to understand why the lacing @Marcel_Rijsmus talked about works.


#12


#13

http://dynamoprimer.com/en/06_Designing-with-Lists/6-1_whats-a-list.html

also important to know:

http://dynamobim.org/introducing-listlevel-working-with-lists-made-easier/


#14

Hello Bim2

I agree with Paul that it is necessary to understand why the lacing is working and how.
But if you use the lacing method be aware of how lacing works

List lacing could become an error if you have input of uneven length, that could happen if you combine a input list by {2 parameters} and {value length 3, value lenght 2}.

If you have a input of two list with different length the result wil be as this picture:


#15

I don’t want to downplay what @Marcel_Rijsmus said as his solution definitely solves the issue, but it is however solving an issue which really doesn’t need really need to be there in the first place. You put brackets around “Comments” and that is not necessary and caused your problem.


#16

When i started dynamo is never used Braces that way (list) I Just connected 5 Element.SetParameter node
after each other to avoid problems :smile:

A little excercise with lacing an list levels:

Thanks to Erik Falck Jørgensen (Erfajo) who once remind me of this :+1:


#17

Hey guys
Many thanks you for your help, I think I got it :slight_smile: