Vla-put-driverspath

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


機能
CAD がビデオ ディスプレイ、ポインティング デバイス、プリンタ、プロッタの ADI デバイス ドライバを検索するフォルダを指定する。


引数
  • vla-object … PreferencesFilesのVLAオブジェクト
  • path … パスの文字列


戻り値
nil


  • MEMO: デバイス ドライバがあるフォルダそれぞれのパスのドライブ文字とパスを指定する。複数のフォルダのリストはセミコロン(;)で区切る。


サンプル
(vl-load-com)
(defun c:Example_DriversPath()
    ;; ドライバーズパスを取得・変更するサンプル
    (setq acadObj (vlax-get-acad-object))
    (setq preferences (vla-get-Preferences acadObj))
  
    ;; 取得
    (setq currDriversPath (vla-get-DriversPath (vla-get-Files preferences)))
    (alert (strcat "現在の DriversPath は " currDriversPath))
    
    ;; 更新
    (setq newDriversPath "TestDriversPath")
    (vla-put-DriversPath (vla-get-Files preferences) newDriversPath)
    (alert (strcat "新しい DriversPath は " newDriversPath))
    
    ;; リセット
    (vla-put-DriversPath (vla-get-Files preferences) currDriversPath)
    (alert (strcat "DriversPath を元に戻す " currDriversPath))
)

関連事項