Help to get family instance referance

revit

#1

Hi can any one help to to get family instance invisible reference please

import clr

clr.AddReference(‘RevitAPI’)
from Autodesk.Revit.DB import *

clr.AddReference(‘RevitNodes’)
import Revit
clr.ImportExtensions(Revit.GeometryConversion)
clr.ImportExtensions(Revit.Elements)

clr.AddReference(‘RevitServices’)
import RevitServices
from RevitServices.Persistence import DocumentManager
from RevitServices.Transactions import TransactionManager

doc = DocumentManager.Instance.CurrentDBDocument

Input elements from revit

“”“line = UnwrapElement(IN[0]).GeometryCurve”""
elements = UnwrapElement(IN[0])

References from objects

elementsRef = ReferenceArray()
opt = Options()
opt.ComputeReferences = True
opt.IncludeNonVisibleObjects = True
opt.View = doc.ActiveView
a = []
for refs in elements:
a.append(refs)
for obj in refs.get_Geometry(opt):
if isinstance(obj, Line):
ref = obj
elementsRef.Append(ref.Reference)

Create dimension line

“”"
TransactionManager.Instance.EnsureInTransaction(doc)

dim = doc.Create.NewDimension(doc.ActiveView, line, elementsRef).ToDSType(True)

TransactionManager
"""
OUT = elementsRef


#2

Any one???

I can get lines but cant convert them to reference if I do I get all NULL values

Regards


#3

Any one ??? Cant get lines to reference.

Looks like all topics about dims is top secret

Regards