本论坛里找VLAX.cls类
- '显示选择集中对象的夹点
- Public Sub ShowSelectionSetCrips(ByRef ss As AcadSelectionSet)
- Dim LispCode As New VLAX
- Dim objEnt As AcadEntity
-
- With LispCode
- .EvalLispExpression "(setq ss (ssadd))"
-
- For Each objEnt In ss
- .EvalLispExpression "(ssadd " & _
- "(handent " & Chr(34) & _
- objEnt.handle & Chr(34) & ")" & _
- "ss" & _
- ")"
- Next
-
- .EvalLispExpression "(sssetfirst nil ss)"
- .EvalLispExpression "(setq ss nil)"
- End With
- Set LispCode = Nothing
- 'MsgBox "您选择了" & ThisDrawing.PickfirstSelectionSet.Count & "个对象"
- End Sub
|