Vla-put-customdictionary

提供:GizmoLabs - だいたい CAD LISP なサイト
構文
(vla-put-customdictionary vla-object dictionary )


機能
カスタム ディクショナリがある場合、使用するカスタム ディクショナリを指定する。


引数
  • vla-object … PreferencesFiles のVLAオブジェクト
  • dictionary … 使用するカスタム ディクショナリ


戻り値
nil


  • このプロパティは、CAD セッションのカスタム ディクショナリのドライブ、パス、ファイル名を含む。


サンプル
(vl-load-com)
(defun c:Example_CustomDictionary()
    ;; CustomDictionary を取得・変更するサンプル
    (setq acadObj (vlax-get-acad-object))
    (setq preferences (vla-get-Preferences acadObj))
    
    ;; 現在の CustomDictionary 値
    (setq currCustomDictionary (vla-get-CustomDictionary (vla-get-Files preferences)))
    (alert (strcat "現在の  CustomDictionary 値は " currCustomDictionary))
    
    ;; 変更
    (setq newCustomDictionary "TestCustomDictionary.cus")
    (vla-put-CustomDictionary (vla-get-Files preferences) newCustomDictionary)
    (alert (strcat "新しい CustomDictionary 値は " newCustomDictionary))
    
    ;; 戻す
    (vla-put-CustomDictionary (vla-get-Files preferences) currCustomDictionary)
    (alert (strcat "CustomDictionary 値を次に戻しました :" currCustomDictionary))
)

関連事項