Hi,
I'm wondering if Revit API allows edit the path of existing railing elements.
Please let me know if there's any way to implement this or any workaround.
Thank you for your help in advance.
Jinsol
Hi,
I'm wondering if Revit API allows edit the path of existing railing elements.
Please let me know if there's any way to implement this or any workaround.
Thank you for your help in advance.
Jinsol
Put aside accessing an existing railing path, is it possible to create railings (ie new path) via the api?
Put aside accessing an existing railing path, is it possible to create railings (ie new path) via the api?
Can we have mouse events in Revit APIs. I want to create addins which allows me to draw line using mouse.
So I want to use mouse events . I am new in Revit so please guide me that is there any mouse events in Revit Api or not
Can we have mouse events in Revit APIs. I want to create addins which allows me to draw line using mouse.
So I want to use mouse events . I am new in Revit so please guide me that is there any mouse events in Revit Api or not
Ok, lazy me...
Help file:
private void CreateRailing(Document document, Stairs stairs) { Transaction trans = new Transaction(document, "Create Railings"); trans.Start(); // Delete existing railings ICollection<ElementId> railingIds = stairs.GetAssociatedRailings(); foreach (ElementId railingId in railingIds) { document.Delete(railingId); } // Find RailingType FilteredElementCollector collector = new FilteredElementCollector(document); ICollection<ElementId> RailingTypeIds = collector.OfClass(typeof(RailingType)).ToElementIds(); Railing.Create(document, stairs.Id, RailingTypeIds.First(), RailingPlacementPosition.Treads); trans.Commit(); }
I just need to confirm that I can create standalone in the absence of stairs. Dale
Ok, lazy me...
Help file:
private void CreateRailing(Document document, Stairs stairs) { Transaction trans = new Transaction(document, "Create Railings"); trans.Start(); // Delete existing railings ICollection<ElementId> railingIds = stairs.GetAssociatedRailings(); foreach (ElementId railingId in railingIds) { document.Delete(railingId); } // Find RailingType FilteredElementCollector collector = new FilteredElementCollector(document); ICollection<ElementId> RailingTypeIds = collector.OfClass(typeof(RailingType)).ToElementIds(); Railing.Create(document, stairs.Id, RailingTypeIds.First(), RailingPlacementPosition.Treads); trans.Commit(); }
I just need to confirm that I can create standalone in the absence of stairs. Dale
Ok, it appears that Railings require an existing Stair.
Create | Automatically creates new railings with the specified railing type on all sides of a stairs element. |
Is there a suggested workaround? Invisible stairs? Dale
Ok, it appears that Railings require an existing Stair.
Create | Automatically creates new railings with the specified railing type on all sides of a stairs element. |
Is there a suggested workaround? Invisible stairs? Dale
bump
To summarise, is it possible to create railings via API without exisiting stairs (ie free-standing)? My research says no. Thanks, Dale
bump
To summarise, is it possible to create railings via API without exisiting stairs (ie free-standing)? My research says no. Thanks, Dale
Can't find what you're looking for? Ask the community or share your knowledge.