几何尺寸与公差论坛------致力于产品几何量公差标准GD&T (GDT:ASME)|New GPS(ISO)研究/CAD设计/CAM加工/CMM测量

几何尺寸与公差论坛------致力于产品几何量公差标准GD&T (GDT:ASME)|New GPS(ISO)研究/CAD设计/CAM加工/CMM测量 (http://www.dimcax.com/hust/index.php)
-   数据库ObjectDBX (http://www.dimcax.com/hust/forumdisplay.php?f=177)
-   -   【转帖】解开图层语句出错,为什么? (http://www.dimcax.com/hust/showthread.php?t=13895)

yang686526 2009-04-28 04:22 PM

【转帖】解开图层语句出错,为什么?
 
解开图层语句出错,为什么?
www.dimcax.com
解开图层语句出错,为什么?
(vlax-for obj layerall
(vlax-put-property obj 'freeze 0))
这个语句不可以吗,为什么老会出现错误:错误: automation 错误。 图层无效
整个函数,功能:解开所有图层
(defun c:fa() ;解开全部图层
(vl-load-com)
(setq actdoc (vlax-get (vlax-get-acad-object) 'activedocument)
layerall (vlax-get actdoc 'layers)
)
(vlax-for obj layerall
(vlax-put-property obj 'freeze 0)
(vlax-put-property obj 'lock 0)
(vlax-put-property obj 'layeron 1)
)
)
(prompt "\n 解开全部图层")
(princ)
)

check here:


所有的时间均为北京时间。 现在的时间是 05:01 AM.