Hi Rodney,
Here is the first part.
'DXF Group Code Constants
Public Const ENTITY = 0 'an entity
Public Const NAME = 2 'by name (i.e. attribute tag, block name,
etc)
Public Const HANDLE = 5 'entity handle
Public Const LINETYPE = 6 'by linetype
Public Const TEXTSTYLE = 7 'by textstyle
Public Const LAYER = 8 'by layer
Public Const THICKNESS = 39 'by the entity's thickness
Public Const LTSCALE = 48 'by entity linetype scale
Public Const VISIBILITY = 60 'by entity visibility
Public Const COLOR = 62 'by entity color
Public Const SPACE = 67 'Model or Paper space
Public Function CreateSelectionSet(SelectionSet As AcadSelectionSet, _
FilterCode As Integer, _
FilterValue As String) As Boolean
Dim intFilterCode(0) As Integer
Dim varFilterValue(0) As Variant
'assume success
CreateSelectionSet = True
intFilterCode(0) = FilterCode
varFilterValue(0) = FilterValue
SelectionSet.SelectOnScreen intFilterCode, varFilterValue
If Not SelectionSet.Count Then
CreateSelectionSet = False
End If
End Function
Public Sub Test()
Dim objSS As AcadSelectionSet
Dim intFilterCode(0) As Integer
Dim strFilterValue(0) As String
Set objSS = ThisDrawing.SelectionSets.Add("Inserts")
Call CreateSelectionSet(objSS, ENTITY, "INSERT")
MsgBox "Number of entities selected: " & objSS.Count
objSS.Delete
End Sub
Joe
Rodney D. Lester
wrote in message
news:[email protected]...
> When using the .SelectOnScreen method of an AcadSelectionSet, what is the
> easies way to filter so i can select only blocks (preferably with editable
> attributes)?
>
> Rodney
>
>