Specifies a name for a customized prolog section in the acad.psf file.
Supported platforms: Windows only
VBA:
object.PostScriptPrologFile
Type: PreferencesFiles
The object this property applies to.
Read-only: No
Type: String
The name of the postscript prolog section of the acad.psf file to use when performing a PSOUT.
The prolog section is used with the PSOUT AutoCAD command to customize the resulting output. For more information, see the AutoCAD documentation.
VBA:
Sub Example_PostScriptPrologFile() ' This example returns the current setting of ' PostScriptPrologFile. It then changes the value, and finally ' it resets the value back to the original setting. Dim preferences As AcadPreferences Dim currPostScriptPrologFile As String Dim newPostScriptPrologFile As String Set preferences = ThisDrawing.Application.Preferences ' Retrieve the current PostScriptPrologFile value currPostScriptPrologFile = preferences.Files.PostScriptPrologFile If currPostScriptPrologFile = "" Then MsgBox "PostScriptPrologFile is not currently set.", vbInformation, "PostScriptPrologFile Example" Else MsgBox "The current value for PostScriptPrologFile is " & currPostScriptPrologFile, vbInformation, "PostScriptPrologFile Example" End If ' Change the value for PostScriptPrologFile newPostScriptPrologFile = "TestPostScriptPrologFile" preferences.Files.PostScriptPrologFile = newPostScriptPrologFile MsgBox "The new value for PostScriptPrologFile is " & newPostScriptPrologFile, vbInformation, "PostScriptPrologFile Example" ' Reset PostScriptPrologFile to its original value preferences.Files.PostScriptPrologFile = currPostScriptPrologFile If currPostScriptPrologFile = "" Then MsgBox "PostScriptPrologFile is reset to NULL.", vbInformation, "PostScriptPrologFile Example" Else MsgBox "The PostScriptPrologFile value is reset to " & currPostScriptPrologFile, vbInformation, "PostScriptPrologFile Example" End If End Sub
Visual LISP:
(vl-load-com) (defun c:Example_PostScriptPrologFile() ;; This example returns the current setting of ;; PostScriptPrologFile. It then changes the value, and finally ;; it resets the value back to the original setting. (setq acadObj (vlax-get-acad-object)) (setq preferences (vla-get-Preferences acadObj)) ;; Retrieve the current PostScriptPrologFile value (setq currPostScriptPrologFile (vla-get-PostScriptPrologFile (vla-get-Files preferences))) (if (= currPostScriptPrologFile "") (alert "PostScriptPrologFile is not currently set.") (alert (strcat "The current value for PostScriptPrologFile is " currPostScriptPrologFile)) ) ;; Change the value for PostScriptPrologFile (setq newPostScriptPrologFile "TestPostScriptPrologFile") (vla-put-PostScriptPrologFile (vla-get-Files preferences) newPostScriptPrologFile) (alert (strcat "The new value for PostScriptPrologFile is " newPostScriptPrologFile)) ;; Reset PostScriptPrologFile to its original value (vla-put-PostScriptPrologFile (vla-get-Files preferences) currPostScriptPrologFile) (if (= currPostScriptPrologFile "") (alert "PostScriptPrologFile is reset to NULL.") (alert (strcat "The PostScriptPrologFile value is reset to " currPostScriptPrologFile)) ) )