Set material by another parameter

Hello everyone on the forum.
I’m trying to apply material to my conduits by dynamo (the main idea would be to color them, but I believe it’s only right by applying material). As it would have several materials, it is selected according to the filter parameter.
I read several posts like:

But none of them managed to evolve where I can, the material is applied, but when exporting the IFC it comes out in gray.
Has anyone seen something similar or know what can be done?
I am currently applying the following to get it right.


color.dyn (13.2 KB)

Hi @renanemeyer,

It’s probably best to create a single AppearanceAssetElement per material.
Your “Generico” AppearanceAssetElement is applied to 65 different materials.
The problem may also not come from Revit but from your IFC viewer which does not take into account the display of materials.

1 Like

Hello @Alban_de_Chasteigner
Nice noted on this issue. I did the adjustments as per comments.
a1

But when you define the material, it says that the parameter does not exist.