hello ,
i have a direct shape in revit and i want to get the material of this direct shape .
i used element.GetMaterial node but its not working , is there another way to do that please?
Thanks for any help
Test.rvt (2.7 MB)
hello ,
i have a direct shape in revit and i want to get the material of this direct shape .
i used element.GetMaterial node but its not working , is there another way to do that please?
Thanks for any help
Test.rvt (2.7 MB)
@sabra.tarek Element.GetMaterials only worked when you assigned a paint color on that Element.
Hi @sabra.tarek you should be able to get the material from directshape, if you have assigned one…
Thank you @sovitek the node Element.GetMaterial for some reason didnt recognize the geometry in my file .maybe its depends on the nature of the direct shape itself however i tried the Revit lookup tool from the buildingcoder . the material is embedded in the mesh inside the geometry inside the direct shape in a parameter called MaterialElementId. I used then chatgpt to make a python script to retrieve the material name in a list. but thank you alot for your time