running code in acaddoc.lsp that runs on each sheet during publish.

running code in acaddoc.lsp that runs on each sheet during publish.

CADdaddy.com
Collaborator Collaborator
823 Views
3 Replies
Message 1 of 4

running code in acaddoc.lsp that runs on each sheet during publish.

CADdaddy.com
Collaborator
Collaborator

Something changed in the 2018 version.

 

I used to be able to run code in acaddoc.lsp that runs on each sheet during publish (as long as background publishing is turned off).  Since 2018 I'm no longer able to do this.

 

This is a severe setback for me. I've always been able to perform certain tasks automated using LISP during a publish session.  Does anybody know if this is by design?  I'm really  hoping it's a bug.

 

James

 

0 Likes
824 Views
3 Replies
Replies (3)
Message 2 of 4

Scottu2
Advocate
Advocate

CADdaddy,

I have a few questions...

Recently switch from an earlier Autocad version like 2013?

Recently update to Autocad 2018, reinstall?

Do it work on a different station with 2018?

Do the routines in acaddoc.lsp need file access to the drive C: ?

Do the routines require (VL-LOAD-COM)?

 

If the operating system windows 10:

   Was there a recent windows update, like within 30 days?

   Get a Blue Screen 😞

  Use a registry cleaner or system tuneup software?

 

0 Likes
Message 3 of 4

cadffm
Consultant
Consultant

" I'm really  hoping it's a bug."

That should only a problem on your computer or better: With your code (hardest case: a timing prolbem, the simpliest a missing bracket)

 

The theorie of bracket get off when you can run the file (load(findile"acaddoc.lsp")) with the desired result.

 

A timing problem is a little bit harder to find/fix, ut you will a workaround.

For testing use a blank acaddoc.lsp and insert create a object via command.

 

(foreach l (layoutlist) (setvar 'CTAB l)(command "_.CECOLOR" "1" "_.LINE" "0,0" "1000,600" ""))

 

Is it working in the commandline (copy/paste the into the commandline)?

Is it working from a *.lsp by loading via (load "myfile.lsp") or APPLOAD?

Is it working in acaddoc.lsp?

Is it working in acaddoc.lsp when you publish?

4x YES? Then we nee to know your exaclty acaddoc.lsp code (and all other external needed stuff)

 

 

Sebastian

0 Likes
Message 4 of 4

CADdaddy.com
Collaborator
Collaborator

Looks like there is no change.  This seems to be happening to me intermittently and I thought I had isolated the problem.  It's probably something on my end, but in case it's not, here's what I did to troubleshoot today:

 

I did a much more stripped down version of startup apps.  I renamed the ApplicationPlugins folder so no plugins would run and used a one-line acaddoc.lsp so I could clearly see the result: (alert "help!").  I also reset the profile on both 2017 and 2018 versions and added only the path to the folder containing the acaddoc.lsp file.  acad.lsp was deleted.

 

I thought that some addin for 2018 was causing the problem but I enabled the ApplicationPlugins and both versions worked correctly.  I added back-in all the startup items that I had stipped out and everything worked fine again.

 

Next I switched back to my normal profiles in Options and restarted AutoCAD for both versions....and it worked fine again!

 

This problem seems intermittent...I'll also try dialing back on the caffeine a bit....that might help!

 

James

0 Likes