Trace the Tag Host Element on linked Revit Project

Trace the Tag Host Element on linked Revit Project

s04049
Enthusiast Enthusiast
1,260 Views
3 Replies
Message 1 of 4

Trace the Tag Host Element on linked Revit Project

s04049
Enthusiast
Enthusiast

Hi community,

 

I have a Revit project that create a drawings by the Sheet, and that project only link other file and TAG the elements on the Sheet Project.

 

I try to get the Host elements parameter of the TAG by getting the tag parameter, but the tag does not have a element host parameter or anything that i can find which elements is taged by the Tag on the view.

 

Question is here:

is that possible by using the Revit API to get the linked element id or parameter by Trace the Tag on the project?

e.g. pipe, duct, cable tray.

 

Thanks

0 Likes
1,261 Views
3 Replies
Replies (3)
Message 2 of 4

jeremytammik
Autodesk
Autodesk

Dear s04049,

 

All i see off-hand is this post from 2009:

 

http://thebuildingcoder.typepad.com/blog/2009/04/tag-association.html

 

I am checking with the development team whether they have anything newer and more effective to offer.

 

Cheers,

 

Jeremy



Jeremy Tammik
Developer Technical Services
Autodesk Developer Network, ADN Open
The Building Coder

0 Likes
Message 3 of 4

jeremytammik
Autodesk
Autodesk

Did that post help?

 

I looked at the help file and see the hierarchy:

 

  Autodesk.Revit.DB.Element
    Autodesk.Revit.DB.SpatialElementTag
      Autodesk.Revit.DB.Architecture.RoomTag
      Autodesk.Revit.DB.AreaTag
      Autodesk.Revit.DB.Mechanical.SpaceTag
    Autodesk.Revit.DB.IndependentTag
      Autodesk.Revit.DB.Structure.FabricReinSpanSymbol
      Autodesk.Revit.DB.Structure.PathReinSpanSymbol
      Autodesk.Revit.DB.Structure.RebarSystemSpanSymbol

Some of the tags seem to provide properties identifying the tagged element:

 

  IndependentTag.TaggedElementId The LinkElementId of the tagged element.
  IndependentTag.TaggedLocalElementId The id of the tagged local element if any.
  RoomTag.TaggedLocalRoomId The ElementId of the tagged room.
  RoomTag.TaggedRoomId The LinkElementId of the tagged room.

Doesn't the Location property specify the tag location, and isn't that on top of or adjacent to the tagged element?

 

Cheers,

 

Jeremy



Jeremy Tammik
Developer Technical Services
Autodesk Developer Network, ADN Open
The Building Coder

0 Likes
Message 4 of 4

s04049
Enthusiast
Enthusiast
Thank for the answer Jeremy , i will try it later after the chinese new year.
Cheers,

s04049
0 Likes