Activate Attached Detail Groups

@bvs1982 @Cas

Hello,

We keep getting the following error (Revit 2023):

Warning: IronPythonEvaluator.EvaluateIronPythonScript operation failed. 
Traceback (most recent call last):
  File "<string>", line 25, in <module>
Exception: The attached detail group detailGroupTypeId does not match the input view's orientation.
Parameter name: detailGroupTypeId

The Revit API gives the following remark:

Currently, perpendicular elevation views (for example, North and East views) are considered compatible when deciding whether or not to allow a detail group to be displayed in a view. The show operation may generate an error (FailureMessage) based on id if the orientation of the annotations do not match the orientation of the target view (for example, the failure definition DimensionPerpendicularToView). To prevent displaying detail groups in the wrong view, you can check the OwnerViewId of a detail group to make sure it matches the view in which you are trying to display it.

What are we doing wrong? I tried getting the OwnerViewId although those give back -1 (since there is no view). We are working with Floorplans.

Hope you can help!

Does it work with earlier versions?
Worked for 2021:

1 Like

@Vladimir

Thanks!! Your python script seems to work without issues!!

Made my day :smiley: