Jump to content
kArThIcK hAcKeR

AutoCAD - Mass Convert DWG To DXF (Batch Convert DWG To DXF) (Mas DWG Convert)

Recommended Posts

kArThIcK hAcKeR

Hi Guys,:)

 

I Wanted To Mass Convert Some DWGs To DXFs,

So, I looked Around and found some commercial softwares and also some lisp routine, but they didn't workout as i expected so i made a software (to interpret scripts).

Autocad Batch Script Creator.jpg

it works fine in converion of dxfs, so i thought this software might be usefull to some who want to mass convert dxfs,

here is the software: AutoCAD Script Writer.zip

 

This Software doesn't Require Installation, (It Runs Directly)

 

 

 

::REQUIREMENTS::

1. AutoCAD which supports LISP routines (eG; full versions of AutoCAD 2010, But not AutoCAD LT Versions)

 

::Usage::

1. In The "Location Of Files To Be Processed" Box, Paste The Location Where U have ur dwg files. (Default value is "D:\SomeFolder"). Dont Give A Root Location Such As "D:\" or "C:\" etc;

 

2. In The "Command" Box, The Default Code Is Written For DXF Conversion, U can modify and write ur own Macros here, (If U know Acad Scripting Language)

 

3. Pressing the "Create Script" Button will create a "Script.scr" file at the location of the dwg files

 

4. Now Open AutoCAD, Now Press [Control]+[N] In AutoCAD, A New Window will be opened

 

5. Now All U Have To Do Is Drag The "Script.scr", into the AutoCAD's Canvas (which is a blank black window usually)

 

6. And thats it, autocad will start converting the DWGs to DXFs

 

Thanks To Lee-Mac, dbroada & Bill-Tillman for giving me the answer and idea to my previous post,

Edited by kArThIcK hAcKeR

Share this post


Link to post
Share on other sites
pmxcad

You can use a script en use Scriptpro to run multiple drawings.

It places the DXF in the drawing map.

 

PmxCAD

 

 

Script:

 

FILEDIA

0

_SAVEAS

DXF

16

 

FILEDIA

1

Share this post


Link to post
Share on other sites
The GettinBetter

Excellent job buddy 8)

 

Got me out of a fix, may thanks.:D

 

What was it created in/with?

Share this post


Link to post
Share on other sites
naren

hi Karthik,

could you help me write code to convert DWG to PDF as I dont know how to write code

 

 

I Wanted To Mass Convert Some DWGs To DXFs,

So, I looked Around and found some commercial softwares and also some lisp routine, but they didn't workout as i expected so i made a software (to interpret scripts).

[ATTACH]48653[/ATTACH]

it works fine in converion of dxfs, so i thought this software might be usefull to some who want to mass convert dxfs,

here is the software: [ATTACH]48630[/ATTACH]

 

This Software doesn't Require Installation, (It Runs Directly)

 

 

 

::REQUIREMENTS::

1. AutoCAD which supports LISP routines (eG; full versions of AutoCAD 2010, But not AutoCAD LT Versions)

 

::Usage::

1. In The "Location Of Files To Be Processed" Box, Paste The Location Where U have ur dwg files. (Default value is "D:\SomeFolder"). Dont Give A Root Location Such As "D:\" or "C:\" etc;

 

2. In The "Command" Box, The Default Code Is Written For DXF Conversion, U can modify and write ur own Macros here, (If U know Acad Scripting Language)

 

3. Pressing the "Create Script" Button will create a "Script.scr" file at the location of the dwg files

 

4. Now Open AutoCAD, Now Press [Control]+[N] In AutoCAD, A New Window will be opened

 

5. Now All U Have To Do Is Drag The "Script.scr", into the AutoCAD's Canvas (which is a blank black window usually)

 

6. And thats it, autocad will start converting the DWGs to DXFs

 

Thanks To Lee-Mac, dbroada & Bill-Tillman for giving me the answer and idea to my previous post,

Share this post


Link to post
Share on other sites
jedipadre

I needed this to send some parts to our tube laser vendor. Worked perfectly. Thanks!

Share this post


Link to post
Share on other sites
iridium

Hello, I have 120 files in the folder, but it converts only the first file. Please help me

Share this post


Link to post
Share on other sites
kArThIcK hAcKeR
Hello, I have 120 files in the folder, but it converts only the first file. Please help me

 

Oooh i'm back after a long time (o_O)

 

Can you post the return script that you had received (Script.scr), so that i can see what the issue is?

Share this post


Link to post
Share on other sites
iridium
Oooh i'm back after a long time (o_O)

 

Can you post the return script that you had received (Script.scr), so that i can see what the issue is?

 

Hi!

 

Here is the script.

 

Thanks for help!

ScriptX.scr

Share this post


Link to post
Share on other sites
BIGAL

The obvious you dont need to delcare as a defun just run command or load the defun once into acaddoc.lsp then just call the defun (dxfout)

 

A couple of suggestions in scripts the / \ can make the difference

 

Check make a test directory the 200.239 to 200_239 the . may be the problem

 

_.OPEN "D:\\123\\200.239_47.dwg" mspace (command "_.dxfout "" "16" "_.regen" "_.close" "_Y")
or
_.OPEN "D:\\123\\200.240_16.dwg" mspace (TODXF)

Share this post


Link to post
Share on other sites
kArThIcK hAcKeR
Hi!

 

Here is the script.

 

Thanks for help!

 

Hi iridium, as Bigal suggested in the post above the "." (dot) in the file name is what's causing the problem..

If you have a file mass file renamer (suggestion: "Bulk Rename Utility"), try renaming the files from 222.123 to 222_123.

 

Let me know if it worked..

Share this post


Link to post
Share on other sites
iridium
Hi iridium, as Bigal suggested in the post above the "." (dot) in the file name is what's causing the problem..

If you have a file mass file renamer (suggestion: "Bulk Rename Utility"), try renaming the files from 222.123 to 222_123.

 

Let me know if it worked..

 

I have replaced the "." with "_" in the file names. The same problem!

Share this post


Link to post
Share on other sites
kArThIcK hAcKeR

Iridium,

Can you please pack a sample of your 10 files to a zip or rar and paste the link..

I'll extract and see if it's a problem with the dwg or the program execution ...

Share this post


Link to post
Share on other sites
iridium

Hi kArThIcK hAcKeR, here are the files.

DWG.rar

Share this post


Link to post
Share on other sites
kArThIcK hAcKeR

Iridium,

 

i just generated a script with the 10 samples you gave me, I was able to convert them to dxf without any error, please see attachment below..

DXF.zip

 

Follow below steps,

 

Try opening a new autocad window (a new process/close existing drawings and autocads), then in the Autocad's black canvas try dropping the script on to it..

let me know how it went.

Share this post


Link to post
Share on other sites
Eurodude

I remember doing this years ago the other way round. DXF to DWG

scripts always started with filedia 0 cmddia 0 then a file list with the saveas commands etc.

 

Used similar scripts for uprevving large batches of drawings, saved lots of tedium.

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

×