Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Autocad scripting question

Status
Not open for further replies.

Mar71n

Programmer
Joined
Feb 24, 2005
Messages
1
Location
GB

Hello,

I'm new to the forum - hopefully I'll be posting up here more in future...

I have very little autocad scripting knowledge, but I am a programmer, so writing autocad scripts should be no problem.
I'm looking to solve a problem, and I wonder if someone could tell me whether this is even vaguely within the scope of autocad scripts.

I work on many cad files, and these same files are edited by other people. A version control system isn't possible due to several factors I won't go into here. What I want to do is to write a script to evaluate the contents of two cad files, and insert anything not existing in the second drawing from the first.

Even as I write this question, I am fairly sure that I won't be able to do this with autocad scripts - the files could be named to a particular convention (ie file1 and file2) to eliminate the need for any user input (I know scripts can't handle that) - but is it possible to dump the coordinates,layers etc of every object into a text file, so a second script can add any of those objects not already in the second file?

Any input appreciated - hopefully someone can suggest some method I can use to solve this problem, which eats up a lot of time!

Thanks,

Martin
 
Hi Martin,

Seems to me I've seen something similar to this, if I remember right, it didn't dump everything like you want, but I think you might be able to modify it to do what you want without a whole lot of heart-ache. I'm afraid I don't remember where I saw it but a couple of places to start are: cadshack and caddepot .

Once you modify the routine to work how you want, you script/batch the process.

HTH
Todd
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top