没有合适的资源?快使用搜索试试~ 我知道了~
房屋结构注记与楼层注记合并
4星 · 超过85%的资源 需积分: 50 63 下载量 62 浏览量
2013-04-27
23:05:04
上传
评论 13
收藏 3KB TXT 举报
温馨提示
* 1:500地形图有时需合并JMD房屋结构注记与楼层注记. * 此代码能合并标准的注记(楼层注记在结构注记右方),若需扩展(如楼层注记在结构注记上方或下方),请自行扩充代码. *使用方法:在当前窗口输入VBAIDE,复制代码至此,运行,选择要合并的JMD数据,即可合并.
资源推荐
资源详情
资源评论
'该程序针对JMD的房屋结构注记,把相邻的楼层注记合并在一起。
'第一步:选择所有要处理的对象(判断标准是:图层:JMD/类型:TEXT/属性值:字母)
'第二步:遍历所选集,每个对象基点扩展进行文本选择(过滤,若存在则把所选的文本值加到此对象属性中,并删除原对象;无则不动)
Sub TextUnit()
Dim sel1 As AcadSelectionSet
Dim sel2 As AcadSelectionSet
Dim FilterType(0 To 7) As Integer
Dim FilterData(0 To 7) As Variant
Dim FilterType1(0 To 5) As Integer
Dim FilterData1(0 To 5) As Variant
Dim enti As AcadEntity
Dim enti1 As AcadEntity
Dim objtext As AcadText
Dim objtext1 As AcadText
Dim pnt As Variant
Dim p1(0 To 1) As Double
Dim p2(0 To 1) As Double
Dim p3(0 To 1) As Double
Dim p4(0 To 1) As Double
Dim pointsArray(0 To 11) As Double
Dim mode As Integer
FilterType(0) = 8
FilterData(0) = "JMD"
FilterType(1) = 0
FilterData(1) = "TEXT"
FilterType(2) = -4
FilterData(2) = "<OR"
FilterType(3) = 1
FilterData(3) = "@"
'第一步:选择所有要处理的对象(判断标准是:图层:JMD/类型:TEXT/属性值:字母)
'第二步:遍历所选集,每个对象基点扩展进行文本选择(过滤,若存在则把所选的文本值加到此对象属性中,并删除原对象;无则不动)
Sub TextUnit()
Dim sel1 As AcadSelectionSet
Dim sel2 As AcadSelectionSet
Dim FilterType(0 To 7) As Integer
Dim FilterData(0 To 7) As Variant
Dim FilterType1(0 To 5) As Integer
Dim FilterData1(0 To 5) As Variant
Dim enti As AcadEntity
Dim enti1 As AcadEntity
Dim objtext As AcadText
Dim objtext1 As AcadText
Dim pnt As Variant
Dim p1(0 To 1) As Double
Dim p2(0 To 1) As Double
Dim p3(0 To 1) As Double
Dim p4(0 To 1) As Double
Dim pointsArray(0 To 11) As Double
Dim mode As Integer
FilterType(0) = 8
FilterData(0) = "JMD"
FilterType(1) = 0
FilterData(1) = "TEXT"
FilterType(2) = -4
FilterData(2) = "<OR"
FilterType(3) = 1
FilterData(3) = "@"
资源评论
- 地理信息达人2020-09-19可以,值得借鉴
lxyht
- 粉丝: 3
- 资源: 4
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
最新资源
资源上传下载、课程学习等过程中有任何疑问或建议,欢迎提出宝贵意见哦~我们会及时处理!
点击此处反馈
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功