Revit API Forum
Welcome to Autodesk’s Revit API Forums. Share your knowledge, ask questions, and explore popular Revit API topics.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Coordinate set of columns

5 REPLIES 5
Reply
Message 1 of 6
tevion
1936 Views, 5 Replies

Coordinate set of columns

Hi,

good idea to create this forum, the API seems to be quite powerful but also quite complex. Simple tasks might get tricky to solve and so the forum might be a good address to ask for help!

Well, I am looking for a way to get the start and end coordinates (XYZ) of columns out, type Structural Columns. Structural Framing coordinates I get but the columns are family related and that is causing me problems. Maybe someone has an idea how to get those coordinates?

Thanks,
Tevion
5 REPLIES 5
Message 2 of 6
Anonymous
in reply to: tevion

Tevion,

Hmm, great question. I don't see a way to grab the specific XYZ points,
but you could probably interpolate them from the column location (X and
Y from FamilyInstance.Location) and the Top Level (+offset) and Base
Level (+offset) for Z. The built-in parameters
"FAMILY_TOP_LEVEL_PARAM", "FAMILY_TOP_LEVEL_OFFSET_PARAM",
"FAMILY_BASE_LEVEL_PARAM", and "FAMILY_BASE_LEVEL_OFFSET_PARAM" should
give you the top and bottom locations, then get the Z value from the
Level.Elevation for the base and top levels.

You could probably write a quick function that you pass a family to and
it returns the XYZ values.

Hope that helps,
-Danny Polkinhorn
WATG
Honolulu

Tevion wrote:
> Hi,
>
> good idea to create this forum, the API seems to be quite powerful but also quite complex. Simple tasks might get tricky to solve and so the forum might be a good address to ask for help!
>
> Well, I am looking for a way to get the start and end coordinates (XYZ) of columns out, type Structural Columns. Structural Framing coordinates I get but the columns are family related and that is causing me problems. Maybe someone has an idea how to get those coordinates?
>
> Thanks,
> Tevion
Message 3 of 6
Anonymous
in reply to: tevion

From the FamilyInstance (the type of object you should have for a column), you can get the AnalyticalModel. For columns, this will be the derived type AnalyticalModelFrame, which has a Curver proprety (in this case it will be the derived type Line). From the Line, you can get the XYZ coordinates of the column. At least that is how I am doing it and it seems to work.
Message 4 of 6
tevion
in reply to: tevion

Danny,

thanks a lot for your precious comment / idea! Finally I get the XY coordinates I was looking for, just the Z coordinates are still driving me crazy.
The Z value according the Level.Elevation I got too, but the built-in parameters are not talking to me, means the routine to inquire them doesn't work as I thought. I made my routines with VB and maybe that wasn't that good idea, should have done it with C#: at the moment I am looking for the get_parameters function (C#) in VB but didn't find it. Any good idea for a built-in parameter inquire function?

Again, thanks a lot for your help!
Tevion
Message 5 of 6
tevion
in reply to: tevion

Ishulok,

sounds good, will try that for sure! Even to get the X Y Z coordinates directly, without to inquire the particular built-in parameters, would be great!

Thanks,
Tevion
Message 6 of 6
Anonymous
in reply to: tevion

Looks like I was wrong. What I describe works OK for beams or braces, but for columns, you should get the AnalyticalModelFrame.Profile.DrivingCurve. The AnalyticalModelFrame.Curve was giving me the same Z node at top and bottom of the column.

Liz

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk DevCon in Munich May 28-29th


Rail Community