Getting Door Paramaters

Getting Door Paramaters

ivas0016
Contributor Contributor
549 Views
6 Replies
Message 1 of 7

Getting Door Paramaters

ivas0016
Contributor
Contributor

Hi,

I posted a similar question regarding the walls in Revit. Now I want to get door width length and height, it would also be great if I could figure out on which side is the door handle. However, the wall had wall class, I noticed that door doesn't have this. I cannot access the door simply by looking for 'Length' parameter, becuase the architects like to add in a word before the 'length', ie 'XXXX.Length'. I tried to do this automation task without using the door, but it seems like I really need it. Any help would be greately apprecaited!

0 Likes
550 Views
6 Replies
Replies (6)
Message 2 of 7

Mohamed_Arshad
Advisor
Advisor

HI @ivas0016 

you have to follow same procedure what you have done in wall

For Type Parameters

you have to use OfClass as  FamilySymbol and OfCategory as Doors

For Instance Parmareters

you have to use OfClass as FamilyInstance and OfCategory as Doors

 

Hope this helps 🙂


Mohamed Arshad K
Software Developer (CAD & BIM)

Message 3 of 7

ivas0016
Contributor
Contributor

but doors doesnt have a class and I dont want to use LookUpParameter. Is there any other way?

0 Likes
Message 4 of 7

TripleM-Dev.net
Advisor
Advisor

Hi @ivas0016 ,

 

See @Mohamed_Arshad post,

For OfClass, Doors are FamilyInstances (for the placed door) and FamilySymbol (for the door type)

Which you need depends on how the parameters are defined as intance or type.

 

For OfCategory, use BuiltinCategory.OST_Doors (BuiltInCategory Enumeration  )

 

FamilyInstance and  FamilySymbol  are inherited from element, so you could use GetParameters  and evaluate each name for the correct one.

 

- Michel

 

 

0 Likes
Message 5 of 7

ivas0016
Contributor
Contributor

Maybe I am not understanding you correctly, but I am trying to say that I can't really use the door parameters, because the names of the parameters are really random. I had the same issue for walls but then I used wall class, but you can't do that here.

0 Likes
Message 6 of 7

mhannonQ65N2
Collaborator
Collaborator

The Height, Width, and Thickness are all BuiltInParameters (CASEWORK_HEIGHT, CASEWORK_WIDTH, and FAMILY_THICKNESS_PARAM respectively) on the FamilySymbol. If the door families in your project(s) do not use these parameters or use them incorrectly, then maybe your users/organization could adopt some standards for door families.

0 Likes
Message 7 of 7

TripleM-Dev.net
Advisor
Advisor

Hi @ivas0016,

 

A Wall is a SystemFamily, it's width is a fixed part of Revit, for walls no parameters can be added that change it's geometry.

 

Doors are UserFamily, so it's up to the User creating the family to provide usefull parameters which 'drive' the geometry (and/or use the builtin ones if started with the correct Family template) or have parameters (names) defined by the company.

 

With GetParameters you have access to all parameters of that (door) family, you need to figure out which one is what.

This can be done by defining a dictionary of Parameter names (To which the user have to conform.) that can define the door Width etc, and give a error / message if none  or multiple are found.

 

A alternative approach would be to analyse the geometry itself, but with that it also depends how and what is exactly modelled by the user.

 

- Michel

0 Likes