如何根据扩展数据过滤图元?
本帖最后由 dong20030432 于 2018-5-3 09:07 编辑我能够用简单的lsp命令得到标题栏的扩展数据如下:请问如何用VB代码过滤出标题栏对象?如何获取其中的数据?比如我要获取material属性对应的材料是什么,如何对其重新赋值?
((-1 . <图元名: 7ee89360>) (0 . "INSERT") (330 . <图元名: 7ee6ecf8>)
(5 . "164") (100 . "AcDbEntity") (67 . 0) (410 . "Model") (8 . "0") (100 .
"AcDbBlockReference") (2 . "*U1") (10 415.0 5.0 0.0) (41 . 1.0) (42 . 1.0) (43
. 1.0) (50 . 0.0) (70 . 0) (71 . 0) (44 . 0.0) (45 . 0.0) (210 0.0 0.0 1.0) (-3
("INTECAD_HUST_CAD_CENTER" (1000 . "TITLE") (1002 . "{") (1000 . "type") (1000
. "heada") (1000 . "name") (1000 . "headd") (1000 . "length") (1040 . 180.0)
(1000 . "height") (1040 . 56.0) (1000 . "rightbottompoint") (1011 415.0 5.0
0.0) (1000 . "ceset") (1070 . 0) (1000 . "maintf") (1070 . 1) (1002 . "}")
(1000 . "OBJECT") (1002 . "{") (1000 . "OBJECTID") (1000 . "TITLE") (1002 .
"}") (1000 . "INTECAD") (1002 . "{") (1000 . "VERSION") (1000 . "V60") (1002 .
"}") (1000 . "TITDATA") (1002 . "{") (1000 . "prop1") (1005 . "0") (1000 .
"prop2") (1005 . "0") (1000 . "name") (1005 . "0") (1000 . "code") (1005 . "0")
(1000 . "material") (1005 . "0") (1000 . "totalpaper") (1005 . "0") (1000 .
"no") (1005 . "0") (1000 . "weight") (1005 . "0") (1000 . "scale") (1005 .
"1B5") (1000 . "prop3") (1005 . "0") (1000 . "prop10") (1005 . "0") (1000 .
"prop13") (1005 . "0") (1000 . "prop18") (1005 . "0") (1000 . "prop27") (1005 .
"0") (1000 . "prop4") (1005 . "0") (1000 . "prop12") (1005 . "0") (1000 .
"prop14") (1005 . "0") (1000 . "prop19") (1005 . "0") (1000 . "prop26") (1005 .
"0") (1000 . "prop6") (1005 . "0") (1000 . "prop9") (1005 . "0") (1000 .
"prop17") (1005 . "0") (1000 . "prop22") (1005 . "0") (1000 . "prop25") (1005 .
"0") (1000 . "prop5") (1005 . "0") (1000 . "prop8") (1005 . "0") (1000 .
"prop16") (1005 . "0") (1000 . "prop21") (1005 . "0") (1000 . "prop23") (1005 .
"0") (1000 . "prop7") (1005 . "0") (1000 . "prop11") (1005 . "0") (1000 .
"prop15") (1005 . "0") (1000 . "prop20") (1005 . "0") (1000 . "prop24") (1005 .
"0") (1002 . "}"))))
目前已经知道用getxdata得到扩展数据后,可以通过遍历比较的办法实现以上功能,但感觉程序效率太低,最好能有使用选择集过滤的办法,希望大家帮忙,谢谢了! 高手帮忙!!!
页:
[1]