各位高手帮帮忙,出点注意: 我用VB 编程二次开发CAD 在创建选择集时遇到问题 具体代码如下: Public acadapp As Object '建立Application对象  ublic acaddoc As Object '建立Document对象  ublic acaddocs As Object Dim ssetObj As Variant On Error Resume Next get_statue = False Set acadapp = GetObject(, "AutoCAD.application.16") '若AutoCad已启动 , 则直接得到一个 Application对象 If Err Then Err.Clear Else get_statue = True Set acaddoc = acadapp.ActiveDocument '设acaddoc为当前图形文件 Set acaddocs = acadapp.Documents End If Set ssetObj = module1.acaddoc.SelectionSets.Add("TEST_SSET1") ' ssetObj.SelectOnScreen module1.acaddoc.SelectionSets.Item("TEST_SSET1").Delete 问题:当从CAD选择晚图形后 回到VB的本地窗口察看时,找不到所选择的对象,仔细看看发现创建的选择集ssetObj 只有Application,Name,cout属性 而没有ITEM属性,所以查不 到,请问怎样解决? 而我在 CAD中的VBA编写的代码就可以看到
VBA代码: Dim selsetCollection As AcadSelectionSets Dim selset1 As Variant Dim ent As Object Dim i, j As Integer
Set selset1 = ThisDrawing.SelectionSets.Add("SS4") selset1 .SelectOnScreen |