Jump to content

Batch DWG to PDF plot LISP File


Recommended Posts

Posted

Hi All, 

 

I have multiple individual dwg files, would like to plot in individual pdf's. Is there any lisp file which can make this task automated?

Posted

Are you using AutoCAD LT 2026 as shown in your profile?

 

Modelspace, paperspace or both?

 

A lot of LISP for plotting around on the WWW, not sure how LT friendly they are.

 

Have you looked or tried any? 

 

Does LT have Batch Plot - Publish AutoCAD 2022 Help | About Publishing | Autodesk AutoCAD 2022 Help | To Publish a List of Drawings to PDF | Autodesk

 

LISP to Batch plot (Publish) Multiple .dwg Models into One PDF - Autodesk Community

 

Batch plot to pdf for DWG and layouts with different path and name - AutoLISP, Visual LISP & DCL - AutoCAD Forums

Posted (edited)

BigAl loves his scripts and I suspect has one to copy and paste in here... though if you search this forum as well there are plenty of pdf and batch examples, just need to put them together. 

I have a PDF LISP (type in "plotPDF" and it creates a PDF in the drawings folder). Regardless what you are doing, typing 7 characters is a lot faster than the menu for PDF, select save folder and so on - so well worth finding one of these on the internet. As a side comment here set up a separate plotter for PDFs without the 'preview' check box - makes things better.

 

The essence of the batch process is to create a script, saved as for example "MyScript.scr" (remember to set the file type to *.* so it saves right as a scr)

 

Here is an example, copy, paste and change for each file you want to plot

 

 

_.OPEN "YOUR_FILE_PATH_AND_FILE_NAME.dwg";;OPens the file
(load "YOUR_PLOTTING_LISP_FILE_PATH_AND_FILE_NAME.lsp");;Loads the LISP
(setvar "ctab" (nth 0 (layoutlist)));;Go to layout '0' (first layout in the layout list)
(YOURPDFPLOTTINGLISP) (OR 'YOURPDFPLOTTINGLISP' );;do the plotting
(if (= dbmod 0) (command ".close"));;if file not modified close
(if (/= dbmod 0)(command ".close" "y"));;if file modified close and "OK to cancel changes"

 

 

Then in a CAD file run the script

 

 

We should one day find the time to make this nice, user friendly and a sticky thread the number of times this gets asked over the years... one day...

Edited by Steven P
  • Funny 1

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...