Closed Koziu233 closed 5 years ago
Since both the walls and the windows are created in the same transaction, Revit does not have enough time to "finalize the walls" prior to hosting the windows in them. You need to split the two in separate transactions so that the walls can be finalized and the model can regenerate. Try putting a Transaction.End
node prior to the FamilyInstance.ByHostAndPoint
.
Hi,
(Sorry for the late reply, and the issue has been closed, so I updated my original question.)
Here is an alternative solution if windows are not cutting the wall when using
FamilyInstance.ByHostAndPoint
Theoretically, as @dimven commented in below, to make the windows cutting the wall, the nodes
Wall.ByCurveAndHeight
(for example) andFamilyInstance.ByHostAndPoint
need to be activated in separate transactions. But putting the nodesTransaction.End
andTransaction.Start
between creating walls and windows never worked.However, it worked when you put them in between creating windows and refreshing windows. Like in the figure shown below. First creating your windows not cutting the walls, then end the transaction, finally refresh these windows. These could be done by both:
Document.DeleteElements
Element.SetParameterByName
Hope this helps anyone.