Jump to content

AutoLisp needed?


jtk07

Recommended Posts

Currently we run Autocad MEP 2011 and I am having a problem getting a lisp to work.

 

Can someone please tell me what lsp file does autocad auto start? It used to work when you would edit the acad2008.lsp file or the acad2004.lsp list but does not seem to work any longer. The lisp I am running is below. its very simple but needed as we have over 200 drawings with this needing done. I plan to open all drawings before I go home and let it run through the motions over night.

 

(command "erase" "W" "-4',3'10" "2.5,-9.1875" "")

(command "qsave")

(command "close")

 

 

any advise on what or how to add a lsp to autoload for each drawing being opened in autocad 2011 MEP.

 

Thanks

Edited by SLW210
Add Tags
Link to comment
Share on other sites

ACADDOC.lsp

 

Don't alter the lsp files that you mention.

 

If the ACADDOC.lsp doesn't exist, create it in Notepad (or another code editor), and save it to the support path.

 

Looks like you want to be using a script though.

Link to comment
Share on other sites

"DANGER Will Robinson!" :shock:

 

First, I highly recommend that you do not modify any ACAD[YYYY].lsp file, and instead place all of your customized routines in ACADDOC.lsp (a user maintained file that resides in the AutoCAD support path).

 

Second, what you're attempting to do, can be easily done with a script (.SCR) file.

 

With a script, you can designate exactly which drawings to open, and what actions to take on each drawing. There are many automated script utilities, but you can easily write your own.

 

*IF* this is the first time you are going to perform such an action (using your own script), then I would for safety sake, save a backup copy of your drawings first.

Link to comment
Share on other sites

ACADDOC.lsp

 

Don't alter the lsp files that you mention.

 

If the ACADDOC.lsp doesn't exist, create it in Notepad (or another code editor), and save it to the support path.

 

Looks like you want to be using a script though.

 

 

...You beat me to it, Lee :D

Link to comment
Share on other sites

All Thanks for the FAST Replys! I got it fixed. Slip of the mind i ran appload and then added it to my startup suite and created MY OWN Lsp file insead of modifying the others. Thanks for the advise!!!

Link to comment
Share on other sites

You're welcome jtk :)

 

I would advise against the Startup Suite - there are known bugs with that utility - and it can be temperamental.

 

If you have your own lsp, just load/call it from the ACADDOC.lsp using the load function:

 

(load "myLISP.lsp" nil)

 

or

 

(load "C:\\...\\Folder\\myLISP.lsp" nil)

 

if not in the Support Path.

Link to comment
Share on other sites

i have it saved "C:\Program Files\Autodesk\AutoCAD MEP 2011\Support\acad2011jtk.lsp"

 

all that is in the acad2011jtk.lsp file is the following.

[color=#ff8c00](command "erase" "W" "-4',3'10" "2.5,-9.1875" "")[/color]

[color=#ff8c00](command "qsave")[/color]

[color=#ff8c00](command "close")[/color]

 

I need something that loads all the time for the next 200 drawings. That is why I have chosen to go with this utility (autocad claimed it has been fixed since 2010 release not sure tho). I do not understand how to convert it to a scrip or make it an auto run file. It needs to be seamless so i can run it on a vacant station and continue working at my desk.

 

we had a run in with someone adding text to each sheet space in the binding strip with information that should have been in the titleblock, now we have duplicate text and trying to get it out before we get further along on this project.

Edited by SLW210
Link to comment
Share on other sites

I need something that loads all the time for the next 200 drawings.

 

... Why not simply use a script...? :?

 

...

Looks like you want to be using a script though.

 

 

...

what you're attempting to do, can be easily done with a script (.SCR) file.

...

 

Instead of manually opening each of your 200 drawings, you start the script and go get a cup of coffee. :wink:

Link to comment
Share on other sites

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...