Select chain of lines by pressing tab key

Select chain of lines by pressing tab key

Anonymous
Not applicable
1,437 Views
4 Replies
Message 1 of 5

Select chain of lines by pressing tab key

Anonymous
Not applicable

In Revit if I want to select a chain of lines or walls or ducts for example, I can hover my mouse on top of one of those line segments and press tab. Revit will find the interconnected lines and highlight them, then I can click to select them.

I am trying to have Rrevit do this on an API command. How do I tell Revit to select all the lines in a chain by pressing the tab key so that I can get the chain of lines?

 

Thank you.

0 Likes
1,438 Views
4 Replies
Replies (4)
Message 2 of 5

jeremytammik
Autodesk
Autodesk

I am not aware of any Revit API support for this functionality.



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

0 Likes
Message 3 of 5

Anonymous
Not applicable

Jeremy,

 

Thanks for the prompt reply. I found the CurveLoop class but I don't really understand if it relates to what I am asking.

 

thanks again.

0 Likes
Message 4 of 5

jeremytammik
Autodesk
Autodesk

Dear Redskyrc,

 

No, probably not.

 

A curve loop is used to describe a closed profile.

 

The string of connected lines that you describe does not fall into this category.

 

Best regards,

 

Jeremy



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

0 Likes
Message 5 of 5

Revitalizer
Advisor
Advisor

Dear redskyrc,

 

you will have to do the calculation by yourself.

 

Just get neighbouring curves by comparing their end points with your given curve's ones.

 

You will find a similar approach in the "Touching Beams" sample:

http://thebuildingcoder.typepad.com/blog/2012/09/filter-for-touching-beams-using-solid-intersection....

 

Also, you could have a look at the TraverseSystem sample in the SDK.

 

The point is to traverse the system/beams/lines recursively.

 

 

Best regards,

Revitalizer

 

 




Rudolf Honke
Software Developer
Mensch und Maschine





0 Likes