Add Family Instance by Location ( point/plane )

Hello guys,

I have a problem with the node of Addfamilyinstance.bylocation.
This node is working fine with the point input, but when I’m trying to place it by plane the family element doesn’t follow the plane rotation. As you see in the pictures, the floor opening supposes to rotate accordingly to the plane input.

Or if place first the family and then rotate the family later the output is NULL. Does Rhino.inside has the node like dynamo ( FamilyInstance.SetRotation).

Thank you guys,


The trick is to create a plane and use a plane to specify the point and rotation of the family on insert. This sample at the end covers the creation and use of the plane for rotation:

1 Like

Hello Scott,

I have tried your suggestion to create the plane, and yes it’s working, but only working for the Famly that not embedded with a host like furniture or etc.

But when I tried with the Family that embedded to the host, the rotation of the family is not accordingly to the given plane.

Here is the Screenshot of my trials.

Thank you

Not working family rotation (embedded inside the host)

Working Famliy rotation (without host)

Hey @s.mazlan
What do you mean by family embedded inside a host?

Hi @eirannejad

Maybe my sentence is not correct. Sorry for that, What I mean is the Hosted Family and Non-Hosted Family.

The Addfamilyinstance.bylocation only working with Non-Hosted Family as the previous Screenshot.

When I’m using the “Deckenöffnung Rechteckig” family (hosted family) for the floor, the outcome doesn’t rotate as the Plane input.
Thank You

Hey @s.mazlan
I created a quick python script node that realigns the family instances to the given plane after they are placed.

Take a look at these example files

Align Family (519.1 KB)

I also filed an issue to correct this behaviour:

Hi @eirannejad,

I tried your script and its work within your example file, but when I tried to copy the Phyton Node (Align Instance) to my file, Its does not work and gave me an error.

The instance(s) actually not out side of the host. its still in the host family.

Thank You.

Would you mind sharing a sample model and the family that your are using plus your GH definition so I can replicate the error on my side and attemp to provide a solution?

Thanks :slight_smile:

Hi @eirannejad,

This is the file of mine. Thank you for willing to help me.

Best Regards.

Rotating (6.8 MB)

1 Like

Okay so the clash points that you are collecting are not scaled to the Revit model units.

This is the location of the instance:

And this is the plane origin that you are trying to reorient to:

I changed the python node to reorient based on the location of the instance itself but use the X and Y axis directions from the plane:

Also added data type checks. Change the python code to this:

import clr

from System import Enum

import rhinoscriptsyntax as rs
import Rhino
import RhinoInside
import Grasshopper
from RhinoInside.Revit import Revit, Convert
from Autodesk.Revit import DB

doc = Revit.ActiveDBDocument


if isinstance(I, DB.FamilyInstance) and isinstance(L, Rhino.Geometry.Plane):
    t = DB.Transaction(doc, "Align Instance")
    I.Pinned = False
    I.SetTransform(I.Location.Point, L.XAxis.ToHost(), L.YAxis.ToHost())
    I.Pinned = True

Here is proof of work:


Thanks for your amazing work. I copy your script and paste it to the new python node, and its work.

*ps: In addition, I introduce an output to the Python node so I can continue to work with the element

Thank you :star_struck: :star_struck:

1 Like

Align Family (338.5 KB)

Hi @eirannejad

I wanted to test out the python script you put together and was wondering if you could tell me why the family by location throws an error when you try to flip the plane vertically along the curve. My simple example file extracts one plane, remakes the plane with a vertical rotation, and then tries to place a simple block. Thanks in advance!

hello I’ve downloaded the script but there is an error saying 1. Solution exception:‘FamilyInstance’ object has no attribute ‘SetTransform’ thank you for your work and efforts

Hey sorry for the very late reply. A couple of issues here

  • The family that is shared needs to be edited so it is not “Always Vertical”
  • Families that are expected to be placed at arbitrary orientations, need to be “Work-Plane Based”
  • The component seems to have a bug. An issue AND a fix has been posted here and should solve the problem for the next release

Hi Guys,

Is this only applicable for family instance? not applicable for detail item or generic annotation family?
My scenario is I am inserting a revision triangle which a generic annotation family on top
right hand of the revision cloud with an offset distance. The idea is to select all those points from multiple sheets and them insert the revision cloud triangle, this will save time from manual insertion on every point and sheet.


Since detail items are view dependent, they utilize a different component to be added to view… the component is called Add Detail Item and is available from V1.8 RC2

Thanks Mohamed, what if the location of the cloud and revision triangle are with in the sheet but outside the viewport, can we base the location thru sheet space? thanks.

Can you show me / provide an example of what you are trying to achieve

Hi Mohamed, I would to place/insert the revision triangle beside the revision cloud, like this? thanks.
It so happen that I cannot get the revision triangle family.

Are the triangles going to be placed on Sheets directly, or are they going to be placed inside views?.. and are they detail items or annotation symbols ?