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: 

Automatic creation of section views

1 REPLY 1
SOLVED
Reply
Message 1 of 2
jeroen.vanvlierden
206 Views, 1 Reply

Automatic creation of section views

I am writing an addin that creates section views for all the windows in a project, inspired by this article of Jeremy Tammik

 

https://thebuildingcoder.typepad.com/blog/2012/06/create-section-view-parallel-to-wall.html

 

already 10 years old, but the code works like a charm, when the walls are located on the ground floor!

however there is something wrong when I try to use this code on the second floor of a testproject

 

does somebody see what needs to be adjusted?

 

1 REPLY 1
Message 2 of 2

Found it!

need to consider the elevation of the view

 

var elevation = uidoc.ActiveView.GenLevel.Elevation;
XYZ min = new XYZ(-w, minZ - offset - elevation, -offset);
XYZ max = new XYZ(w, maxZ + offset - elevation, 0);

 

but without the example, provided in 2012, I would not have been able to do it

 

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

Post to forums  

Rail Community


Autodesk Design & Make Report