设置 QNEW 命令的默认模板文件名。 支持的平台:仅窗口 属性值只读:不 类型:字符串 要使用的默认图形样板的文件名。 言论此属性的值控制与 QNEW 命令一起使用的默认模板。若要使用此属性,必须将对象声明为对象。PrefrencesFiles 例子工 务 局: Sub Example_QNewTemplateFile() ' This example uses a template file named MyTemplate.dwt to ' set a default template for the QNEW command. ' You should change the example to use ' a template file on your computer. Dim MyTemplate As AcadPreferencesFiles Set MyTemplate = AcadApplication.Preferences.Files MyTemplate.QNewTemplateFile = "C:\MainTemplate.dwt" End Sub Visual LISP: (vl-load-com)
(defun c:Example_QNewTemplateFile()
;; This example uses a template file named MyTemplate.dwt to
;; set a default template for the QNEW command.
;; You should change the example to use
;; a template file on your computer.
(setq acadObj (vlax-get-acad-object))
(setq preferences (vla-get-Preferences acadObj))
(vla-put-QNewTemplateFile (vla-get-Files preferences) "C:\\MainTemplate.dwt")
)
|
|Archiver|CAD开发者社区
( 苏ICP备2022047690号-1 苏公网安备32011402011833)
GMT+8, 2025-10-29 08:50
Powered by Discuz! X3.4
Copyright © 2001-2021, Tencent Cloud.