Dim ssetObj As AcadSelectionSet
Set ssetObj = ThisDrawing.SelectionSets.Item("TEST_SSET2")
ssetObj.Clear
Dim p As Variant
Dim dd(100) As Double
ii = 0
Do Until Err 0
On Error GoTo msg
p = ThisDrawing.Utility.GetPoint(, "选点")
s = s & Format(p(0), "##.##") & " " & Format(p(1), "#.##") & vbCrLf
dd(ii) = p(0): dd(ii + 1) = p(1): dd(ii + 2) = 0#
ii = ii + 3
Loop
msg:
'MsgBox Err.Description & " " & Err.Number & Err.Source
ReDim points(0 To ii - 4) As Double
For I = 0 To ii - 4
points(I) = dd(I)
Next I
Dim mode As Integer
mode = acSelectionSetCrossingPolygon