Author Topic: How To run LISP in BACH  (Read 13362 times)

0 Members and 1 Guest are viewing this topic.

Marc'Antonio Alessi

  • Swamp Rat
  • Posts: 1453
  • Marco
Re: How To run LISP in BACH
« Reply #15 on: January 28, 2014, 05:59:54 AM »
Another behaviour: in Bricscad (only) -pubblish with minimal DSD

example

[DWF6Sheet:1 (1)-Model]
DWG=E:\__Temp\DwgSmall\1 (1).dwg
Layout=Model

I get a print to default printer.

Andrea

  • Water Moccasin
  • Posts: 2372
Re: How To run LISP in BACH
« Reply #16 on: January 28, 2014, 10:26:34 AM »
there is my contribution...
Why not using PUBLISH ?
Awesome Andrea!

BTW, why use the Startup Suite? Is it simply to avoid problems with the ACadDoc.LSP file? I'd have thought it might even be easier to simply rename the old existing ACadDoc.LSP (if it exists) then create a new temporary one which loads the renamed one (as well as your lisp), then runs the publish command so the user can select the files, and after publish completes delete the temporary ACadDoc and rename the old one back.

Thanks Irneb,
I've tested acaddoc also,...and seem to work well,...but for the common of user, acaddoc may have diffrent setting and or in a network drive and set at read-only mode.
in our office,...depending the client program used,...acaddoc is diffrent and use diffrent location depending the AutoCAD profile set. It is also recommanded to check the file attribute before writing something in it....some client have "Weird" tool here making some file in read-only mode during their program process.
so I tought that it was easy to use the startup suit case...

Just sharing my 2 cents.
Keep smile...

ur_naz

  • Newt
  • Posts: 68
  • Made in Ukraine
Re: How To run LISP in BACH
« Reply #17 on: January 28, 2014, 03:32:43 PM »
foolish but

ronjonp

  • Needs a day job
  • Posts: 7529
Re: How To run LISP in BACH
« Reply #18 on: January 28, 2014, 03:49:44 PM »
 ;D

Windows 11 x64 - AutoCAD /C3D 2023

Custom Build PC

kruuger

  • Swamp Rat
  • Posts: 637
Re: How To run LISP in BATCH
« Reply #19 on: February 19, 2014, 09:23:55 AM »
In "NoPubblish" folder there are files that have not been processed by AutoCAD.
same here. don't know why but some files are not processed with publish :(
k.

Marc'Antonio Alessi

  • Swamp Rat
  • Posts: 1453
  • Marco
Re: How To run LISP in BACH
« Reply #20 on: February 19, 2014, 09:48:34 AM »
In "NoPubblish" folder there are files that have not been processed by AutoCAD.
same here. don't know why but some files are not processed with publish :(
k.

Thanks for testing, I have abandoned this route because it is slowest of the script and Bricscad I always print all the files... The most important reason why I do not like scripts is that when launched I lose control of the process in particular in case of error.
Ciao.

Andrea

  • Water Moccasin
  • Posts: 2372
Re: How To run LISP in BACH
« Reply #21 on: February 19, 2014, 10:13:38 AM »
Ciao Marc'Antonio..

are you using the script with publish ?
Keep smile...

Marc'Antonio Alessi

  • Swamp Rat
  • Posts: 1453
  • Marco
Re: How To run LISP in BACH
« Reply #22 on: February 19, 2014, 11:07:54 AM »
Ciao Marc'Antonio..

are you using the script with publish ?

No... "I have abandoned this route because it is slowest of the script and Bricscad I always print all the files..."
Now I use scripts.

Ciao.

Andrea

  • Water Moccasin
  • Posts: 2372
Re: How To run LISP in BACH
« Reply #23 on: February 19, 2014, 11:11:06 AM »
Ciao Marc'Antonio..

are you using the script with publish ?

No... "I have abandoned this route because it is slowest of the script and Bricscad I always print all the files..."
Now I use scripts.

Ciao.


I agree,...it is not very fast,..
but it can help in some case....
just sharing the info.

Gracie !
Keep smile...

Marc'Antonio Alessi

  • Swamp Rat
  • Posts: 1453
  • Marco
Re: How To run LISP in BACH
« Reply #24 on: February 19, 2014, 11:27:34 AM »
Gracie !
The best way for me is (was  :realmad: ):
(vl-cmdf "_.VBASTMT" "documents.item(documents.count-1).sendcommand \"(load ....)... )
Prego.

Andrea

  • Water Moccasin
  • Posts: 2372
Re: How To run LISP in BACH
« Reply #25 on: February 19, 2014, 12:18:34 PM »
??  maybe need to explore this alternative..?

Code - Lisp: [Select]
  1.   (vla-put-Visible
  2.     (vlax-create-object
  3.       (strcat "AutoCAD.Application."
  4.               (substr (getvar 'acadver) 1 2)
  5.       )
  6.     )
  7.     :vlax-false
  8.   )

Keep smile...

fixo

  • Guest
Re: How To run LISP in BACH
« Reply #26 on: February 19, 2014, 12:34:51 PM »
my guess is "_.VBASTMT" isn't working in higher acad version

Marc'Antonio Alessi

  • Swamp Rat
  • Posts: 1453
  • Marco
Re: How To run LISP in BACH
« Reply #27 on: February 19, 2014, 12:43:13 PM »
my guess is "_.VBASTMT" isn't working in higher acad version
it works, but:
Quote
So if I use VBASTMT in >= 2010 I need to load VBA
(x64VBAServer.exe on 64 bit) and *everything* runs 6-8x slower,
including AutoCAD commands! It is much true particularly if you
must use many commands inside of the Lisp function.
Then I need to close AutoCAD to restore previous speed.
see: http://www.theswamp.org/index.php?topic=43869.msg491387;topicseen#msg491387 and others...

Andrea

  • Water Moccasin
  • Posts: 2372
Re: How To run LISP in BACH
« Reply #28 on: February 19, 2014, 03:39:11 PM »
this bug as been fixed in our offices by reinstalling MSOffice 64bits.
just let you know...
Keep smile...

Marc'Antonio Alessi

  • Swamp Rat
  • Posts: 1453
  • Marco
Re: How To run LISP in BACH
« Reply #29 on: February 20, 2014, 05:51:07 AM »
this bug as been fixed in our offices by reinstalling MSOffice 64bits.
just let you know...
thank you, will try this solution