Element.SetName not working as expected

Hi All!

I am having an issue with getting Element.SetName to work the way I want. I am trying to rename Object Styles, and My list is coming up as the Fail output, with an empty success.

Here is what I have so far:

Any direction is greatly appreciated!
ObjectStyleRenameV1.dyn (43.4 KB)

Your graph looks pretty messy (i.e. difficult to understand.)

Maybe you want to clean it up optically and / or post the script?

Cheers,
Matt

Hi Matt,

I added the dynamo script to the original post, Sorry for it being muddy, I’m pretty new still.

Thanks!

Looks like it didnt upload before for some reason, I have corrected that and the script is in the post.

If you want to clean your script up visually, just hit CTRL + L.
It may not look amazing, but it will certainly be easier to follow than what it looks like now.

Can you do that and repost a screenshot?

Not sure why you are mapping so many things. I think it is probably easiert to just boolean mask your way to a filtered list. I would have done it like this:

I couldn’t open your script. It told me it was corrupted.
image

Other than that, I think you may generally run into issues trying to change the names of graphicstyles in Revit. Apparently it isn’t supported?


Thank you for your assistance @m.owens! I tried searching here but must have missed those topics, I’ll do some more research and see if maybe a workaround is possible with Python script nodes. If I find a solution I will post it here.