大家好,我是这个论坛的新手,我涉足过VBA,到目前为止我还不是专家
我正在尝试找出一种分解维度的方法。如有任何建议,我们将不胜感激。
谢谢,
丹
- Sub ExplodeDim()
- Dim sstext As AcadSelectionSet
- Dim blk As AcadBlockReference
- Dim oEnt As AcadEntity
- Dim FilterType(1) As Integer
- Dim FilterData(1) As Variant
- On Error Resume Next
- ThisDrawing.SelectionSets.Item("XDim").Delete
- Set sstext = ThisDrawing.SelectionSets.Add("XDim")
- FilterType(0) = 67
- FilterData(0) = 0
- FilterType(1) = 0
- FilterData(1) = "Dimension"
- sstext.Select acSelectionSetAll, , , FilterType, FilterData
-
- For Each oEnt In sstext
- If TypeOf oEnt Is AcadDimAligned Then
- If oEnt.TextColor = 5 And oEnt.TextOverride " " And oEnt.TextOverride "" Then
- 'Explode Dim here
- End If
- End If
- Next
- End Sub
本帖以下内容被隐藏保护;需要你回复后,才能看到! 游客,如果您要查看本帖隐藏内容请 回复 |