Sets the color book path.
Supported platforms: Windows only
VBA:
object.ColorBookPath
Type: PreferencesFiles
The object this property applies to.
Read-only: No
Type: String
The color book path.
No additional remarks.
VBA:
Sub Example_ColorBookPath()
'This example changes the color book path
'and then sets it to its original string
Dim pref As AutoCAD.AcadPreferencesFiles
Set pref = AcadApplication.Preferences.Files
Dim defCBPath As String
Dim changedCBPath As String
defCBPath = pref.ColorBookPath
MsgBox "The current color book path is " & defCBPath
pref.ColorBookPath = "c:\winnt;c:\temp"
changedCBPath = pref.ColorBookPath
MsgBox "The changed color book path is " & changedCBPath
pref.ColorBookPath = defCBPath
End Sub
Visual LISP:
(vl-load-com)
(defun c:Example_ColorBookPath()
;; This example changes the color book path
;; and then sets it to its original string
(setq acadObj (vlax-get-acad-object))
(setq pref (vla-get-Files (vla-get-Preferences acadObj)))
(setq defCBPath (vla-get-ColorBookPath pref))
(alert (strcat "The current color book path is " defCBPath))
(vla-put-ColorBookPath pref "c:\\winnt;c:\\temp")
(setq changedCBPath (vla-get-ColorBookPath pref))
(alert (strcat "The changed color book path is " changedCBPath))
(vla-put-ColorBookPath pref defCBPath)
)