Reputation: 447
I'm currently porting some AutoCAD VBA code to .NET and came across the following part:
Dim oSSetObj As AcadSelectionSet = Nothing
oSSetObj = ThisDrawing.SelectionSets.Add(SelSet_Prev)
oSSetObj.SelectAtPoint(pInsertionPoint)
So, I have a given point and I want to select all elements at this point. I took a look at different methods of the SelectionSet
and the Editor
class, but none of them seem to fit to my requirement.
How can I select all elements in AutoCAD .NET at a given point? The solution should work in AutoCAD 2008 and 2011.
Upvotes: 2
Views: 3114
Reputation: 13296
I'm afraid you have to iterate over the whole database: http://through-the-interface.typepad.com/through_the_interface/2006/11/two_methods_for.html
Upvotes: 2