Replace all instances of one family with another with instance parameters maintained-Pushes one Parameter value to all parameters

Hi All,

As the title says, I am working on a script to change all instances of one family to another, while maintaining their instance parameters of the original family.

I am hitting a bit of a wall here. . . I am not getting any errors, but my output does nothing, showing only a list of the family to replace several times and no changes in model.

Apologies in advance for my nightmare of a filtering group, but I couldn’t get it to work with other filtering methods I tried. Code block to list.contains to a filter by bool was removing things it shouldn’t have. I now it is not elegant, open to any advice, but not the issue I’m having specifically.

If I make it as a one off for a specific family with the specific names of parameters it works fine, the goal is to be able to use it for multiple families (at different times of course) regardless of name or number of instance parameters.

Image of workspace:

Here is an image showing what I tried for making the filtering cleaner/more legible:


It was removing parameters it should not have, and leaving ones it should, so i am not sure where I went wrong. . .

Here is a copy of the .dyn:
ReplaceFamilyIntsances-TESTNEW.dyn (80.9 KB)

Any advice is appreciated. I have tried searching the forums, but no luck on finding another thread with what I am looking for.

Does anyone know why clockworks “All Elements of Family Type+” node is pulling metal stud details, and not instances of the break line family I am trying to pull?

Edit: Attempting to pull parameters directly from the family types node pulls all the parameters except the instance parameters? Any reason for that?

Using the info from this thread (which I somehow missed before):Copy all parameter values from one Family instance to another - #12 by David_Baldacchino

I went with a list.map, per the suggestions in the above thread, This works. . . sort of. It changes the families to the new type as desired, nut makes all parameters identical, which is not desired. I’m hitting a wall here. . . . any guidance on why the mapping would be doing this?

Updated workspace picture:

Note: The node “FilterToOnlyWritaleInstanceParameters” is a custom node of the filter group from the first post, just to remove clutter from my graph for sanity reasons.