Message 1 of 5
can t delet selectionset

Not applicable
12-23-2006
05:18 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Hello
it drives me crazy ...
i want to check if selection set already exist , if yes then delete it. but it seems it works not every time. after the second time i can t create the selectionset. acad says its already exist.
here my code
Dim ssetObj As AcadSelectionSet
Dim ssetObj2 As AcadSelectionSet
Dim ObjSS As AcadSelectionSet
For Each ObjSS In ThisDrawing.SelectionSets
Debug.Print ObjSS.Name
If UCase("Regio_SSET") = UCase(ObjSS.Name) Or UCase("Subt_SSET") = UCase(ObjSS.Name) Then
ThisDrawing.SelectionSets.Item(anzi).Delete
End If
anzi = anzi + 1
Next
Set ssetObj = ThisDrawing.SelectionSets.Add("Regio_SSET")
.....
it drives me crazy ...
i want to check if selection set already exist , if yes then delete it. but it seems it works not every time. after the second time i can t create the selectionset. acad says its already exist.
here my code
Dim ssetObj As AcadSelectionSet
Dim ssetObj2 As AcadSelectionSet
Dim ObjSS As AcadSelectionSet
For Each ObjSS In ThisDrawing.SelectionSets
Debug.Print ObjSS.Name
If UCase("Regio_SSET") = UCase(ObjSS.Name) Or UCase("Subt_SSET") = UCase(ObjSS.Name) Then
ThisDrawing.SelectionSets.Item(anzi).Delete
End If
anzi = anzi + 1
Next
Set ssetObj = ThisDrawing.SelectionSets.Add("Regio_SSET")
.....