All generic model

All generic model

sonicer
Collaborator Collaborator
2,396 Views
2 Replies
Message 1 of 3

All generic model

sonicer
Collaborator
Collaborator
How can I get all generic model family with specific type parameters
0 Likes
Accepted solutions (2)
2,397 Views
2 Replies
Replies (2)
Message 2 of 3

aignatovich
Advisor
Advisor
Accepted solution

Hi!

 

Firstly you can find family symbols with specific parameter values, using .WhereElementIsElementType() method combined with parameters filter(s), search "ElementParameterFilter" in chm file from Revit SDK and ElementCategoryFilter.

 

Then use FamilyInstanceFilter to find family instances of specific family symbols you've founded earlier.

0 Likes
Message 3 of 3

jeremytammik
Autodesk
Autodesk
Accepted solution

The largest collection of filtering samples can probably be found in The Building Coder samples module CmdCollectorPerformance.cs:

 

https://github.com/jeremytammik/the_building_coder_samples/blob/master/BuildingCoder/BuildingCoder/C...

 

All samples presented there are discussed and explained in some blog post or other.

 

Cheers,

 

Jeremy



Jeremy Tammik
Developer Technical Services
Autodesk Developer Network, ADN Open
The Building Coder