Preferences 属性 (ActiveX)
获取 Preferences 对象。 支持的平台:仅限 Windows 言论该对象保存“选项”对话框中的选项,这些选项驻留在注册表中。可以通过对象找到驻留在图形中的选项。PreferencesDatabasePreferences 例子VBA: Sub Example_Preferences() ' This example returns the current setting of ' LogFilePath from the preferences object. Dim preferences As AcadPreferences Set preferences = ThisDrawing.Application.Preferences ' Retrieve the current LogFilePath value MsgBox "The current value for LogFilePath is " & preferences.Files.LogFilePath, , "Preferences Example" End Sub 可视化 LISP: (vl-load-com) (defun c:Example_Preferences() ;; This example returns the current setting of ;; LogFilePath from the preferences object. (setq acadObj (vlax-get-acad-object)) (setq preferences (vla-get-Preferences acadObj)) ;; Retrieve the current LogFilePath value (alert (strcat "The current value for LogFilePath is " (vla-get-LogFilePath (vla-get-Files preferences)))) ) |
|Archiver|CAD开发者社区 ( 苏ICP备2022047690号-1 苏公网安备32011402011833)
GMT+8, 2024-12-15 22:02
Powered by Discuz! X3.4
Copyright © 2001-2021, Tencent Cloud.