Find & Replace Element names Using Dynamo Globally

Hello Dynamo World,

This is my first post in the Forum and New to Dynamo, Using the latest Dynamo for Revit 2020

I need some help creating a Dynamo file that will let me find and replace part of names that has, example XYZ_viewport to ABC-viewport < just need to replace the XYZ_ and leave the rest of the name. I would need to do this for all categories, like i.e. Callout tags, section bubble head, region fills, line styles.

Basically a Global find and replace of the suffix of the name. I’m not sure if this is possible.

In lieu of find & replace. I could use a Global find and delete of elements with the suffix XYZ_

Paste what you have so far.

Hi Alien, thank you for replying.
I’m fairly new to this and been peacing together from other posts that i found on Viewports and got it to work on view ports to delete that type. See

Well you’ve got no matches. The == node means identical to. It doesn’t not mean contains.
So unless the element names are exactly what you’ve written in the code block it won’t find them.

Allen,
Thanks for repling back. Sorry i didnt reply soon. Its been super busy in our office that havent had time to even look back in Dynamo. Ill have to search for a node that is “contains” Once i get some free up time.