Lee Mac 发表于 2022-7-6 07:29:33

 
如果确保必要的块位于AutoCAD支持路径中(可能位于所有用户通用的网络支持路径中),则程序将能够在需要时定位和插入块(取决于程序的编写方式)。

fabriciorby 发表于 2022-7-6 07:30:51

 
怎么做,嗯
这似乎是一个很好的解决方案

Lee Mac 发表于 2022-7-6 07:36:34

 
您的程序是如何创建块引用的?INSERT命令/entmake/vla insertblock?
块是否位于AutoCAD支持路径中?

fabriciorby 发表于 2022-7-6 07:38:39

 
是的,块位于AutoCAD支持路径中。但它们都在一个大图纸中
只是

Lee Mac 发表于 2022-7-6 07:44:12

 
在“大dwg”中运行此命令,将每个块导出到单独的文件:
(defun c:blk2dwg ( / def dir dwg )
   (setq dir (getvar 'dwgprefix))
   (while (setq def (tblnext "BLOCK" (null def)))
       (if (zerop (logand 125 (cdr (assoc 70 def))))
         (if (not (findfile (setq dwg (strcat dir (cdr (assoc 2 def)) ".dwg"))))
               (command "_.-wblock" dwg "=")
         )
       )
   )
   (princ)
)

fabriciorby 发表于 2022-7-6 07:46:27

 
世界跆拳道联盟
你太棒了!
谢谢你,李

Lee Mac 发表于 2022-7-6 07:49:51

不客气
页: 1 [2]
查看完整版本: 从dwg fi导入块