Create ElementType

Create ElementType

Anonymous
Not applicable
859 Views
6 Replies
Message 1 of 7

Create ElementType

Anonymous
Not applicable

Hello,

 

I have spend some time now on trying to create a new ElementType. I understand that the only way to so is to duplicate an existing elementType. However this results in the following problem:

If you would like to create a new wall you could querry the curent default type, however this could be one of several possible System Family Types "Basiswand" "Geschichtete Wand" "Fassade". However if you need a "Basiswand" and the default is set to "Fassade" you run in a problem later on when working with the elementtype and changing its properties e.g. the CompoundStructure ...

 
Same goes for a floortype this could be e.g. a "Geschossdecke" or a "Bodenplatte".

 

The problem is that the only location where you can querry the familyNames is within the ElementTypes and this retuns the names in a lokalized form. So if I would use these names to determine the ElementType to duplicate it will fail as soon as somebody uses another language...

 

Any Ideas?

 

 

0 Likes
Accepted solutions (1)
860 Views
6 Replies
Replies (6)
Message 2 of 7

Revitalizer
Advisor
Advisor

Hi,

 

for the WallType, check its Kind property.

WallKind.Basic is the one you need.

Language independent.

 

Revitalizer




Rudolf Honke
Software Developer
Mensch und Maschine





0 Likes
Message 3 of 7

Anonymous
Not applicable

Okay I am aware of Kind, however this is not generally applicable to all ElementTypes. So it will not work for floortypes. Ever tried to create a Floor with a foundation slab type?

Both run under FloorType, however two different create functions....

0 Likes
Message 4 of 7

Revitalizer
Advisor
Advisor

Hi,

 

there is FloorType.IsFoundationSlab property, is this what you need?

 

 

Revitalizer




Rudolf Honke
Software Developer
Mensch und Maschine





0 Likes
Message 5 of 7

Anonymous
Not applicable

No I need somethink where I can discinguish these things from ElementType level not for each Subclass.

 

Or someway how to get a language independend familyName...

 

so that I can now that "Fassade" ==  "Curtain Wall" == in russian == in french == in manadrin ...

0 Likes
Message 6 of 7

Anonymous
Not applicable

Hello I solved it somehow.

 

However I would like to file a feature request:

an accessible language independen value referencing the SystemFamilyType of an Element.

0 Likes
Message 7 of 7

jeremytammik
Autodesk
Autodesk
Accepted solution

Is there an entry for that in the Revit Idea Station?

 

  • Yes: please vote for it
  • No: please create one

 

Thank you!

 

Best regards,

 

Jeremy

 



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

0 Likes