Is possible to set a value from a Material Parameter in a Family?
Perfect! I was trying a node i made and set the rest of parameters despite the Material. I’ll check that one, i think i have it.
Thanks a lot for your time and solution.
Hi again @Kulkul I just tried that solution.
It says Check Parameter Type.
The only difference between your solution and mine is the Element.ID node. Could be that?, or did you modify the Set Active Famiy Parameter By Name?
Yes use that. BTW do you have “Material” Parameter in Family properties?
Use that it means “your node” or the one i’m using already?
By the way, i checked the exception and says:
Exception: The storage type of family parameter is not a double type or integer type.
Parameter name: familyParameter
My node Element.Id returns an integer. Should return an Element ID for make the Set Active Family Parameter By Name work?
- The Material prameters is a Type Parameter, is in Family Properties, would be any different if would be an instance parameter ?
@Raul.Galdran Follow exactly my instructions on the gif.
Excuse me, i found the node Element.ID, thought didn’t have it in my library. Now it worked!
Thanks for your time.
Hello @Kulkul! Please repost your solution.
The ‘All Elements of Type’ didn’t work for me, not sure what’s changed…
Here’s my version…
Hope that helps,
import clr # Import DocumentManager and TransactionManager clr.AddReference("RevitServices") import RevitServices from RevitServices.Persistence import DocumentManager # Import RevitAPI clr.AddReference("RevitAPI") import Autodesk from Autodesk.Revit.DB import * clr.AddReference("RevitNodes") import Revit clr.ImportExtensions(Revit.GeometryConversion) clr.ImportExtensions(Revit.Elements) from Revit.Elements import * doc = DocumentManager.Instance.CurrentDBDocument fec = FilteredElementCollector(doc).OfClass(Autodesk.Revit.DB.Material) materials =  for material in fec: materials.append([material.Name, material.Id]) OUT = materials