Automate Choosing material image for IFC in Revit

Hi wonderful community,

New to Dynamo, always wanted to get into it and see huge potential with it and our workflows.

But I’m currently looking at one of the most repetitive and boring tasks I’ve ever been asked to do in Revit.

Essentially I have an IFC of a manufactured CLT building imported into Revit, approx 1450 elements.

1st issue is the import has converted each element as an In-Place object.
2nd issue is each element has its own unique material, 1450 of them.

My task is to convert the Grey IFC to look like timber. The only way I’ve found to do that in Revit is to manually change each element > material appearance > input path to image folder, one by one…and while this is only 1450 x 3 clicks away, once it is done once it will be asked to be done again in the future. (I know 3Ds Max would probably be the right place to do this, but they want section cuts etc in the renders too).

I get how some of the nodes etc work in Dynamo but I think a bit of help with this script will help me put the pieces together.

Thank you all!!

Can you verify that the IFC parameter really drives the material? I would rather imagine that the in-place elements have a type parameter that could just be None or Default at the moment, which could be easy to fix at once. Anyway, if I am mistaken, here are some tips to get started:

Hi Yna!

Right you are, if I edit the in-place element they each have a type parameter

Then it could simply work this way:

  • Select all walls with the nodes Categories / All Elements of Category
  • Set their type parameter with SetParameterByName(TypeOrInstance) from Rhythm (use Material.ByName to select the material value)

Sorry Yna I don’t think I’ve quite followed you,


Warning: Element.SetParameterByName operation failed.
No parameter found by that name.

The parameter name is “Material” and you will need a Material.ByName node to select the material element (it has to be inserted between the code block containing “CLT Yoker” and the input for the value):

Ok, Rythm installed, Dynamo updated, I’ve got this built…

But nothing really happened, and yes I’ve hit Run :slight_smile:

Thank you so much if you manage to crack this!!!1

Tried this too,

but no change to the model

In this case, it could be that the material of these elements is simply set in the Object Styles dialog in Revit. Did you also try to change the Walls Material there?