How to get family and its type from an Element

How to get family and its type from an Element

Anonymous
Not applicable
1,833 Views
1 Reply
Message 1 of 2

How to get family and its type from an Element

Anonymous
Not applicable

Hello everyone,

 

Let's say I have the following code snippet.

Element element =  doc.GetElement(id);

So, I wonder can I use API to get the family name and family type name of an element?

 

Thank you

 

0 Likes
1,834 Views
1 Reply
Reply (1)
Message 2 of 2

jeremytammik
Autodesk
Autodesk

Dear Ali,

 

First of all, if you run into questions like this, you should definitely take the time to work through the getting started material. It covers all such basic question in full and depth:

 

http://thebuildingcoder.typepad.com/blog/about-the-author.html#2

 

Secondly, you can easily discover and explore such relationships interactively using RevitLookup:

 

https://github.com/jeremytammik/RevitLookup

 

Third:

 

 

Cheers,

 

Jeremy

 



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

0 Likes