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: 

Point element and its Reference are in different locations in Multistory Stair

4 REPLIES 4
SOLVED
Reply
Message 1 of 5
faulknerkyle
416 Views, 4 Replies

Point element and its Reference are in different locations in Multistory Stair

I'm writing a script in dynamo to dimension stairs and I'm having a problem with reference points in multistory stairs. 

 

The points from get_Geometry() are returned correctly, but the references for the points that belong to the "copied" stairs are referencing the points of the original stair. See below a little script that illustrates this case. The script is simply taking the point, finding its reference, and grabbing the geometry from that reference. For the "copied" stairs, this returned point is not the input point as I would expect, but rather the corresponding point on the original stair.

 

Is this a bug? The point is the best reference for me for the dimension, but if there is an alternative I could use I am looking for suggestions. Otherwise my fall back is to draw a detail line and dimension to that.

faulknerkyle_0-1585669945441.png

 

4 REPLIES 4
Message 2 of 5
jeremytammik
in reply to: faulknerkyle

Glad to hear that you have a viable fallback.

 

In addition, I hope that you can glean some useful further ideas from this extensive discussion on multistory stairs and challenges that sound partially related to the one you are facing:

 

https://forums.autodesk.com/t5/revit-api-forum/multistorey-stair-subements/m-p/8349447#M34200

 



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

Message 3 of 5
faulknerkyle
in reply to: jeremytammik

Thank you this is great info. Don't know how I missed it in my searching.

 

While it doesn't help to figure out what is happening with the points, it gives me an idea to use that point data to find a face in the geometry at the same elevation (which would be top of landing) and use that as a reference instead of using a detail line. 

 

On a related note, when I get the top face of a landing by this path: Stairs > StairsLanding > Geometry > Face > Reference, the resulting dimension is invisible. But if I use this path: Stairs > Geometry > Face > Reference, the created dimension is visible as expected. Not sure why this is the case. I tried some of the previous solutions, such as creating a new dimension with using the references of the invisible dimension, but that didn't work.

 

Thanks again for the help. I think I have what I need to the script working.

Message 4 of 5
faulknerkyle
in reply to: faulknerkyle

AH HA!!  I think I have found the problem.

 

My script was set up to take a multistair and get the unique stairs within that multistair via GetAllStairsIds(). (This is important because the multistair can have unpinned stairs in it and I need all the unique stairs within that multistair so that I can get the proper info I need). From there, I would get the geometry from each stair (and its copies if they exist) and attempt to get the references from the points that define the run, as shown in my original post. This is where the reference from the 'copied' stairs would wrongly return the reference to the corresponding point on the original stair.

 

BUT...

 

If I get the geometry from the multistair element directly, and acquire the references from the points from that geometry, all the references are in the correct position in relation to the point. SUCCESS!

 

Only problem is now I have to query the geometry twice: once from the individual stairs so that I can maintain a relationship between the points of the runs and the information pulled from that run, and then once from the multistory stair so that I can match the points from the first query to the points from this second query to get the correct references.

 

Hopefully this makes sense. 

Message 5 of 5
jeremytammik
in reply to: faulknerkyle

Congratulations on solving this and glad I could help!

 

I saved your discoveries for posterity in the blog:

 

https://thebuildingcoder.typepad.com/blog/2020/04/-stair-point-references-bim360-users-zoom-jobs.htm...

 

Thank you very much for your explanation!

 



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

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