Message 1 of 4
Adding a item with it's ObjectID to a selection set.

Not applicable
02-07-2000
08:00 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
I was trying to add an entity to a selection set. I'm hacking
up your CAO example so I have its ObjectID.
up your CAO example so I have its ObjectID.
'***this is what have so far:
Dim pick As
AcadSelectionSet
With ThisDrawing.SelectionSets
Do
While .Count > 0
.Item(0).Delete
Loop
End With
Set pick =
ThisDrawing.SelectionSets.Add("omar")
pick.Clear
'**** code
from CAO
If linkSel Is Nothing Then
MsgBox "No
link!"
Exit Sub
End If
' Get selected link
Dim link As
CAO.link
Set link = linkSel.Item(SpinButtonLinkIndex.Value - 1)
If
link Is Nothing Then
MsgBox "Unable to retrieve
this link"
Exit Sub
End If
pick.AddItem link.objectId '<---- gives a
"Object does not support method" error
Is there a way to convert the linked entity’s ObjectID
into a format, which the selection set method will accept?
Or is the another
way to accomplish this?
into a format, which the selection set method will accept?
Or is the another
way to accomplish this?