明经CAD社区

 找回密码
 注册

QQ登录

只需一步,快速开始

搜索
12
返回列表 发新帖
楼主: liminnet

这是不进CAD图层对框话可以建图层的最好办法,现在想修改.

  [复制链接]
 楼主| 发表于 2008-6-12 17:55:00 | 显示全部楼层
提示: 作者被禁止或删除 内容自动屏蔽
发表于 2008-6-13 11:35:00 | 显示全部楼层
  1. (defun c:TT (/ a col lty txt)
  2.    (setq a   (entget (tblobjname "layer" (getvar "clayer")))
  3.          col (getvar "cecolor")
  4.          lty (getvar "celtype")
  5.    )
  6.    (if (setq txt (entsel "\n选择文字: "))
  7.      (if (snvalid (setq txt (cdr (assoc 1 (entget (car txt))))))
  8.        (setq a (subst (cons 2 txt) (assoc 2 a) a))
  9.        (princ "\n** 文字内容不能作为有效层名 **")
  10.      )
  11.    )
  12.    (if (not (wcmatch col "BY*"))
  13.      (setq a (subst (cons 62 (atoi col)) (assoc 62 a) a))
  14.      (princ (strcat "\n当前颜色 " col " 无意义。"))
  15.    )
  16.    (if (not (wcmatch lty "By*"))
  17.      (setq a (subst (cons 6 lty) (assoc 6 a) a))
  18.      (princ (strcat "\n当前线型 " lty " 无意义。"))
  19.    )
  20.    (entmod a)
  21.    (princ)
  22. )
 楼主| 发表于 2008-6-13 13:26:00 | 显示全部楼层
提示: 作者被禁止或删除 内容自动屏蔽
您需要登录后才可以回帖 登录 | 注册

本版积分规则

小黑屋|手机版|CAD论坛|CAD教程|CAD下载|联系我们|关于明经|明经通道 ( 粤ICP备05003914号 )  
©2000-2023 明经通道 版权所有 本站代码,在未取得本站及作者授权的情况下,不得用于商业用途

GMT+8, 2025-6-19 08:49 , Processed in 0.159235 second(s), 19 queries , Gzip On.

Powered by Discuz! X3.4

Copyright © 2001-2021, Tencent Cloud.

快速回复 返回顶部 返回列表