[VBA]请问:选择集过滤器为何不可用
<PRE>Dim SsetObj As AcadSelectionSet<BR>Dim filterType(0) As Integer, FilterDate As Variant<BR>filterType(0) = 0<BR>FilterDate = "Line"<BR>ThisDrawing.SelectionSets("AA").Delete<BR>Set SsetObj = ThisDrawing.SelectionSets.Add("AA")<BR> SsetObj. filterType, FilterDate</PRE><PRE>显示的错误为filterType, FilterDate参数在SelectOnScreen不可用</PRE><PRE>请问有什么方法可以解决?</PRE><PRE>如果用句柄遍历所有对象怎么样去做,请明示.谢谢</PRE> 1、FilterDate = "Line"<BR>?dim FilterDate(0) As Variant
FilterDate(0) = "Line"<BR>
2、HandleToObject方法 不行啊
错误为:找不到主健 前面加上on error resume next Sub SSet()<BR>On Error Resume Next<BR>Dim SsetObj As AcadSelectionSet<BR>Dim filterType(0) As Integer, FilterDate(0) As Variant<BR>filterType(0) = 0<BR>FilterDate(0) = "Line"<BR>ThisDrawing.SelectionSets("AA").Delete<BR>Set SsetObj = ThisDrawing.SelectionSets.Add("AA")<BR>SsetObj.SelectOnScreen filterType, FilterDate
End Sub<BR> 谢谢各位的帮助
我的问题已经得到解决
我会努力学的更好
页:
[1]