Jump to content
ben_vk

How do i batch convert 150+ dwg to pdf?

Recommended Posts

ben_vk

Hi Guys,

 

We have been supplied over 150 dwg files and I have been assigned the task of exporting them all to PDF. Is there a batch processor that is capable of doing this task? I can see software that will cost $99 and hopefully be able to do it, but im hoping to learn how to do it some other way (if possible!)

 

Has anyone been down this path before and been able to do it?

 

Thanks

Share this post


Link to post
Share on other sites
ben_vk

I posted this in AutoCAD Customisation, but think the question may belong here...

 

We have been supplied over 150 dwg files and I have been assigned the task of exporting them all to PDF. Is there a batch processor that is capable of doing this task? I can see software that will cost $99 and hopefully be able to do it, but im hoping to learn how to do it some other way (if possible!)

 

Has anyone been down this path before and been able to do it?

 

Thanks

Share this post


Link to post
Share on other sites
gazza_au

Have you got Acrobat X Pro at work?

 

 

 

Convert AutoCAD files in batches

 

 

  1. Choose Adobe PDF > Batch Conversion.
  2. Specify your preferences for layers, page size, plot style, and output PDFs. Click Conversion Settings to specify the Acrobat PDFMaker settings.
  3. In the DWG List, do any of the following:
    • Click Add Folder or Add Files, and then specify the folder or files.
    • To load a previously saved list of files, click Append List, and then specify the list.
    • As needed, expand individual files and select or deselect the items you want, such as model space and layouts. To exclude or include all model space, click the associated buttons.
    • To exclude a file from the conversion, deselect the file box. As needed, select or deselect all of the files in the list, change the order of the files, remove files, or clear the list.
    • To show the complete file paths, select Expand File Name(s).
    • To save the DWG list for later use, click Save List. This action saves the list in its current state, including the file order and file selections. You can retrieve this list at any time by clicking Append List.

 

[*]Click Convert.

[*]Once the conversion is finished, you can click Save Details to save a log file of the conversion.

Share this post


Link to post
Share on other sites
MSasu

Please check the PUBLISH built-in command.

Share this post


Link to post
Share on other sites
asos2000

Is not PUBLISH do that task?

Search on net for this progran "AcroPlot"

Share this post


Link to post
Share on other sites
ben_vk

I am looking at PUBLISH as we speak, i think this should work for what I require. Thanks for your help guys

Share this post


Link to post
Share on other sites
RobDraw

No external program is needed. AutoCAD can produce the PDFs and you can batch plot using PUBLISH.

 

Hopefully the layouts are all set-up correctly. If not there is a way to import a page set-up from within publisher.

Share this post


Link to post
Share on other sites
LibertyOne
Hi Guys,

 

We have been supplied over 150 dwg files and I have been assigned the task of exporting them all to PDF. Is there a batch processor that is capable of doing this task? I can see software that will cost $99 and hopefully be able to do it, but im hoping to learn how to do it some other way (if possible!)

 

Has anyone been down this path before and been able to do it?

 

Thanks

 

Man, that type of job sucks -- soon as I get home I'll post some code that someone could possibly change to work with your situation...

Share this post


Link to post
Share on other sites
LibertyOne

Oooooo....just looked into my code...and it's a bit complicated because the code was meant to place a plot stamp on a drawing in model space where the drawing border and title block were scaled up to a certain size to match the scale of the drawing in model space. None of the drawings were in paper space. Each drawing was read and it knew which sheet size (A4, A3. A2, A1, A0), where the border was positioned and what scale it had. It then entered the stamp and then plotted to pdf. We had about 450 drawings and divided them out between the three of us. While the other two guys were doing everything manually, I set out to write a program to do it automatically. I finished it in about a half hour and had my 150 drawings plotted in pdf about 20 minutes later. Of course I shared this with the other guys, and they had their drawings finished two hours ahead of what they would have done manually. So I post the code for you all to pick at:

 

SCRIPT:

filedia 1
-PLOT
J
Model
DWG To PDF.pc3
!md_blatt
Millimeter
Querformat
Nein
F
!md_fen_ul
!md_fen_or
Anpassen
Zentrum
Ja
Plot_SW_Fert03.ctb
Ja
W
!md_file
Nein
Ja
Ja

 

LISP CODE: (I've changed some names around to keep identities secret)

;;STAMP.LSP
;;Adds documentation stamp and stamp number to the drawing.

(defun C:STAMP ( / )

(setq md_filedia (getvar "filedia"))
(setq md_attdia (getvar "attdia"))
(setvar "filedia" 0)
(setvar "attdia" 0)

;;-------------------------------
;;   add stamp
;;-------------------------------

(setq en(car(entsel))) 
(setq elist(entget en)) 
(setq md_sf (cdr (assoc 41 elist)))

(setq md_tb_ul (list -180.0 80.0 0.0))

(setq md_ul_xyz (mapcar '(lambda (a) (* a md_sf)) md_tb_ul))

(setq md_xyz (mapcar '+ md_ul_xyz (cdr (assoc 10 elist))))
;path of stamp
(setq md_path "C:\\Dokumente und Einstellungen\\John.Doe\\Eigene Dateien\\Doku\\stamp.dwg")
(setq stamp-nr (strcat (substr (getvar "dwgname") 1 12) "/" (substr (getvar "dwgname") 14 3)))
(setq md_file (strcat (substr (getvar "dwgname") 1 23)))
(command "_.-insert" md_path md_xyz md_sf "" "" stamp-nr "")
(command "_regen")
(command "_purge" "_a" "*" "_n") 
(command "_purge" "_a" "*" "_n") 
(command "_purge" "_a" "*" "_n") 
(command _"zoom" "_e")

(setvar "filedia" md_filedia)
(setvar "attdia" md_attdia)

;;-------------------------------
;;   print
;;-------------------------------
(setq en(car(entsel))) 
(setq elist(entget en))
(cond
   ( (= (cdr (assoc 2 elist)) "RAHMENA0_L4") (setq md_border_or '(2329.0 841.0 0.0)
                       md_blatt "ISO A0 (841.00 x 1189.00 mm)") )
   ( (= (cdr (assoc 2 elist)) "RAHMENA0_L3") (setq md_border_or '(1949.0 841.0 0.0)
                       md_blatt "ISO A0 (841.00 x 1189.00 mm)") )
   ( (= (cdr (assoc 2 elist)) "RAHMENA0_L2") (setq md_border_or '(1569.0 841.0 0.0)
                       md_blatt "ISO A0 (841.00 x 1189.00 mm)") )
   ( (= (cdr (assoc 2 elist)) "RAHMENA0_L1") (setq md_border_or '(1379.0 841.0 0.0)
                       md_blatt "ISO A0 (841.00 x 1189.00 mm)") )
   ( (= (cdr (assoc 2 elist)) "RAHMENA0") (setq md_border_or '(1189.0 841.0 0.0)
                       md_blatt "ISO A0 (841.00 x 1189.00 mm)") )
   ( (= (cdr (assoc 2 elist)) "RAHMENA1") (setq md_border_or '(841.0 594.0 0.0)
                       md_blatt "ISO A1 (594.00 x 841.00 mm)") )
   ( (= (cdr (assoc 2 elist)) "RAHMENA2") (setq md_border_or '(594.0 420.0 0.0)
                       md_blatt "ISO A2 (420.00 x 594.00 mm)") )
   ( (= (cdr (assoc 2 elist)) "RAHMENA3") (setq md_border_or '(420.0 297.0 0.0)
                       md_blatt "ISO A3 (297.00 x 420.00 mm)") )
   ( (= (cdr (assoc 2 elist)) "RAHMENA4") (setq md_border_or '(210.0 297.0 0.0)
                       md_blatt "ISO A4 (297.00 x 210.00 mm)") )
;    (= T (princ "Kein Rahmen"))
)
(setq md_border_sf (mapcar '(lambda (a) (* a md_sf)) md_border_or))
(setq md_fen_ul (cdr (assoc 10 elist)))
(setq md_fen_or (mapcar '+ md_border_sf (cdr (assoc 10 elist))))

)

 

For all this to work, I created three files.

STAMP.DWG (which was inserted as a block into each drawing)

STAMP.LSP (the lisp file listed above)

STAMP.SCR (the script file listed above)

The drawing borders and title blocks were company standard files and the plot PC3 plus the CTB used for plotting.

 

Have fun picking at it...

Share this post


Link to post
Share on other sites
BIGAL
soon as I get home I'll post some code
Liberty one did you look at my post and the link ?

 

Ben_Vk its your turn now have we been helpfull before we all run away posting code as we are guessing what you want to do next.

Share this post


Link to post
Share on other sites
Tiger

I have merged your two threads into one, please don't post the same question in multiple forums.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×