Room Tag Input

Hello, What should be the input for the tag here?
Thank you.

Anyone?..

Hello,
It is not considered as a tag
It must be specific (roomtag)
I don’t know if it’s possible via the api (not yet enough level)?

Cordially
christian.stan

1 Like

Yeah, I understand.
I even can do it with the API but I wonder how to get the Tag from the selected Room Tag!
Thanks by the way. I will make your reply as solution.

1 Like

It is accessible. Don’t know if there is a node available. But the api can get at it.

import clr
import sys

import System
from System import Array
from System.Collections.Generic import *

clr.AddReference("RevitAPI")
clr.AddReference("RevitAPIUI")

from Autodesk.Revit.DB import *
from Autodesk.Revit.UI import *

doc = __revit__.ActiveUIDocument.Document
app = __revit__.Application
uidoc = __revit__.ActiveUIDocument

selection = uidoc.Selection.GetElementIds()
def GetElementSet(elemIds):
    myElements = []
    for eid in elemIds:
        myElements.append(doc.GetElement(eid))
    return myElements
e = GetElementSet(selection)
e = e[0]
hasLeader = e.HasLeader
hasElbow = e.HasElbow
leaderEndpt = e.LeaderEnd
leaderElbowpt = e.LeaderElbow

print(str(hasLeader) + "\n" + str(hasElbow) + "\n" + str(leaderEndpt) + "\n" + str(leaderEndpt ))
t = Transaction(doc, "Move Leader")
t.Start()
e.LeaderEnd = XYZ(0,0,0)
t.Commit()
3 Likes

Thanks, Aaron.
Great script!

you can bring the solution to Mr. Aaron I think
Good script suite :wink:

Cordially
christian.stan