vlisp file selection function

vlisp file selection function

Anonymous
Not applicable
625 Views
10 Replies
Message 1 of 11

vlisp file selection function

Anonymous
Not applicable
I need to open several (100 or more) drawings and run a custom vlisp
routine that manipulates the drawing before being plotted. I was
wondering if there is a function or routine that can be called from
vlisp that will open up a file dialog box allowing the operator to
select multiple files from either the same directory or various
directories and create a selection set containing the drawing path and
name? With this selection set, I could then loop through it and produce
the needed plots for each drawing.

Does the batch plot process allow for inclusion of running custom
programs?

Thanks for your response.

Brent
0 Likes
626 Views
10 Replies
Replies (10)
Message 2 of 11

Anonymous
Not applicable
Brent,

A couple of suggestions:

First: Doslib, by Mcneel associates
(http://www.mcneel.com/products/doslib.html) has a function to select
multiple files.

Second: I have my acaddoc.lsp check for a file "autoload.lsp" as it loads.
If this file is found on the AutoCAD search path then it is loaded. I often
put lisp commands in this file to run automatically, doing such things as,
changing the date attribute in the title block, inserting or deleting
blocks.

One or the other of these should help you with your task.

Mike Weaver

Brent Blackwelder wrote in message
news:38314AC9.20919211@home.com...
> I need to open several (100 or more) drawings and run a custom vlisp
> routine that manipulates the drawing before being plotted. I was
> wondering if there is a function or routine that can be called from
> vlisp that will open up a file dialog box allowing the operator to
> select multiple files from either the same directory or various
> directories and create a selection set containing the drawing path and
> name? With this selection set, I could then loop through it and produce
> the needed plots for each drawing.
>
> Does the batch plot process allow for inclusion of running custom
> programs?
>
> Thanks for your response.
>
> Brent
0 Likes
Message 3 of 11

Anonymous
Not applicable
DFBrowser v2b.14 handles multiple file or directory collection
within AutoLISP / VLISP programs.

Check my website ...

Jesse Danes
AutoCAD Administrator / MCAD Central Functions
Honeywell, Home & Building Controls

http://www.pclink.com/jdanes/caders/index.htm

Brent Blackwelder wrote in message
news:38314AC9.20919211@home.com...
> I need to open several (100 or more) drawings and run a custom vlisp
> routine that manipulates the drawing before being plotted. I was
> wondering if there is a function or routine that can be called from
> vlisp that will open up a file dialog box allowing the operator to
> select multiple files from either the same directory or various
> directories and create a selection set containing the drawing path and
> name? With this selection set, I could then loop through it and produce
> the needed plots for each drawing.
>
> Does the batch plot process allow for inclusion of running custom
> programs?
>
> Thanks for your response.
>
> Brent
0 Likes
Message 4 of 11

Anonymous
Not applicable
Just a few words of advice.

You shouldn't, and don't need to load a 700+ KB .ARX file
with a LISP interpreter hiding inside of it, just to do
multiple file selection. That is rediculous. Proposing
that as a viable solution, is pure insanity.

DOSLib and a number of other true ARX-based solutions
include a multiple file selection dialog box, and they
typically require less than 60 KB of overhead.

Brent Blackwelder wrote:
>
> I need to open several (100 or more) drawings and run a custom vlisp
> routine that manipulates the drawing before being plotted. I was
> wondering if there is a function or routine that can be called from
> vlisp that will open up a file dialog box allowing the operator to
> select multiple files from either the same directory or various
> directories and create a selection set containing the drawing path and
> name? With this selection set, I could then loop through it and produce
> the needed plots for each drawing.
>
> Does the batch plot process allow for inclusion of running custom
> programs?
>
> Thanks for your response.
>
> Brent

--
/*********************************************************/
/* Tony Tanzillo Design Automation Consulting */
/* Programming & Customization for AutoCAD & Compatibles */
/* ----------------------------------------------------- */
/* tony.tanzillo@worldnet.att.net */
/* http://ourworld.compuserve.com/homepages/tonyt */
/*********************************************************/
0 Likes
Message 5 of 11

Anonymous
Not applicable
Just a few words of advice.

You shouldn't, and don't need to load a 700+ KB .ARX file
with a LISP interpreter hiding inside of it, just to do
multiple file selection. That is utterly rediculous.

DOSLib and a number of other true ARX-based solutions
include a multiple file selection dialog box, and they
typically require less than 60 KB of overhead.

Brent Blackwelder wrote:
>
> I need to open several (100 or more) drawings and run a custom vlisp
> routine that manipulates the drawing before being plotted. I was
> wondering if there is a function or routine that can be called from
> vlisp that will open up a file dialog box allowing the operator to
> select multiple files from either the same directory or various
> directories and create a selection set containing the drawing path and
> name? With this selection set, I could then loop through it and produce
> the needed plots for each drawing.
>
> Does the batch plot process allow for inclusion of running custom
> programs?
>
> Thanks for your response.
>
> Brent

--
/*********************************************************/
/* Tony Tanzillo Design Automation Consulting */
/* Programming & Customization for AutoCAD & Compatibles */
/* ----------------------------------------------------- */
/* tony.tanzillo@worldnet.att.net */
/* http://ourworld.compuserve.com/homepages/tonyt */
/*********************************************************/
0 Likes
Message 6 of 11

Anonymous
Not applicable
The file size is irrelavant and makes no difference with
regard to performance. We have tons of 3rd party arx
applications loaded up with AutoCAD, and many are
well into 500-800 KB in size. The only affect is disk space.
Newer systems with decent memory could care less about a
700KB arx file. But If 700KB files are taxing a hard drive,
its time to get a bigger drive or try the VLX compiled version
which is 78KB. Matter of filesize went out when Bill Gates
and his buddies were still making PC's out of plywood in
their garage back in the 70's

Doslib's function is limited only to selecting multiple files
from the same folder at any one time. Most would agree
that leaves a great deal to be desired. And it does not
include features for selecting directories, search and
collection of files or directories, modifying the window
sizing, etc. And I think most end users could care less whether
it was written in C or VLISP, whats desired is the functionality.

This application was not written for a market or for personal
file size preferences. It was written because I wanted the challenge
of writing such an application in VLISP. And for myown use
in developing applications for interfacing AutoCAD with PDM.
However I felt people might benefit from it, so I made it available
free of charge for personal uses. If you don't like it, don't use it or
write
a better if you think your up to it.

To be honest I am a little suprized filesize is all you could come up with.
I think a house of cards has a better chance of holding up than that
argument.
But alteast the third person flaming shows a little more creativity than the
usual drive by's.

Jesse Danes

Tony Tanzillo wrote in message
news:3831F8EC.33178E72@worldnet.att.net...
> Just a few words of advice.
>
> You shouldn't, and don't need to load a 700+ KB .ARX file
> with a LISP interpreter hiding inside of it, just to do
> multiple file selection. That is utterly rediculous.
>
> DOSLib and a number of other true ARX-based solutions
> include a multiple file selection dialog box, and they
> typically require less than 60 KB of overhead.
>
> Brent Blackwelder wrote:
> >
> > I need to open several (100 or more) drawings and run a custom vlisp
> > routine that manipulates the drawing before being plotted. I was
> > wondering if there is a function or routine that can be called from
> > vlisp that will open up a file dialog box allowing the operator to
> > select multiple files from either the same directory or various
> > directories and create a selection set containing the drawing path and
> > name? With this selection set, I could then loop through it and produce
> > the needed plots for each drawing.
> >
> > Does the batch plot process allow for inclusion of running custom
> > programs?
> >
> > Thanks for your response.
> >
> > Brent
>
> --
> /*********************************************************/
> /* Tony Tanzillo Design Automation Consulting */
> /* Programming & Customization for AutoCAD & Compatibles */
> /* ----------------------------------------------------- */
> /* tony.tanzillo@worldnet.att.net */
> /* http://ourworld.compuserve.com/homepages/tonyt */
> /*********************************************************/
0 Likes
Message 7 of 11

Anonymous
Not applicable
JDanes wrote:
>
> The file size is irrelavant and makes no difference with
> regard to performance.

That's absolutely wrong, but not surprising.

-
/*********************************************************/
/* Tony Tanzillo Design Automation Consulting */
/* Programming & Customization for AutoCAD & Compatibles */
/* ----------------------------------------------------- */
/* tony.tanzillo@worldnet.att.net */
/* http://ourworld.compuserve.com/homepages/tonyt */
/*********************************************************/
0 Likes
Message 8 of 11

Anonymous
Not applicable
JDanes wrote:
>The file size is irrelavant and makes no difference with
>regard to performance.

jesse, it's wasting main memory, not the filesize.
this IS expensive.
the VL runtime is not shared upto 2000.

--
Reini Urban
http://xarch.tu-graz.ac.at/autocad/news/faq/autolisp.html
0 Likes
Message 9 of 11

Anonymous
Not applicable
So we are posting tag team now ?

Such as the nature of langauges that come from the
platform independent or runtime compiled world. They
require a runtime. This is so with Java, Visual Basic,
Common LISP's, and so forth. They are not the performers
as is a C based applications but nor are they that low level.
There is nothing intrinsically wrong with this, and they have
their advantages.

And no its not absolutely wrong, its relative, and as far as I am
concerned you are just nitpicking. Most all new systems are
very high performance. Maybe in older days it was
a bigger issue. Programmers used to nitpick about saving bytes
here and there, to conserve memory use. This
is the reason for the current Y2K business where
the 19 was omitted from the year, but thats just poor planning.
By todays standards, programmers other than those programming
64K EPROM's commonly for appliances, would not last long
at their job if they spent that much time worrying about
file size and memory use. I don't neccessarily agree
with the alternative which has become commonly bloated
windows applications, however this is market based commercial
programming . And until everyone is running Linux, thats
just the way it is.

Anyway, if system resources are an issue and
one is stuck with the 700KB arx which is a limitation
of Vital LISP then its a simple matter to add a demand
based load/unload native lisp such as used by the iges.arx
The dfbrowser arx application is afterall intended for use by a programmer
inside AutoLISP code, so this should be simple business. Or a I said
before, USE THE VLX VERSION WHICH IS 78KB for Visual LISP.

However I am sure you could come up with constructive solutions
as well as I, rather than relatively inflated, baseless criticism.
So as I suggested previously, you are welcome to write one yourself
that suits your file size preferences. So, less chatter and lets see
some code. But I'll not hold it against you if you would rather not
attempt it in VLISP.

Jesse Danes

Tony Tanzillo wrote in message
news:38341158.544D2736@worldnet.att.net...
> JDanes wrote:
> >
> > The file size is irrelavant and makes no difference with
> > regard to performance.
>
> That's absolutely wrong, but not surprising.
>
> -
> /*********************************************************/
> /* Tony Tanzillo Design Automation Consulting */
> /* Programming & Customization for AutoCAD & Compatibles */
> /* ----------------------------------------------------- */
> /* tony.tanzillo@worldnet.att.net */
> /* http://ourworld.compuserve.com/homepages/tonyt */
> /*********************************************************/
0 Likes
Message 10 of 11

Anonymous
Not applicable
JDanes wrote:

> And no its not absolutely wrong, its relative, ....

Yes, is it absolutely wrong. A 500+ KB LISP interpreter
and the overhead that it imposes on an end user, is not a
figment of anyone's imagination.

> and as far as I am concerned you are just nitpicking.

No, not at all. I blasted Autodesk right here in this
newsgroup when they first released Visual LISP 1.0, for
this very reason.

--
/*********************************************************/
/* Tony Tanzillo Design Automation Consulting */
/* Programming & Customization for AutoCAD & Compatibles */
/* ----------------------------------------------------- */
/* tony.tanzillo@worldnet.att.net */
/* http://ourworld.compuserve.com/homepages/tonyt */
/*********************************************************/
0 Likes
Message 11 of 11

Anonymous
Not applicable
JDanes wrote:
>So we are posting tag team now ?

BTW: we are actually working of packaging a cormanlisp.arx together with
the dll and image to ONE 3-4MB thing which carries everything in one
file. this is now really bloated, but might be acceptable for this very
special application with 1-3 users world-wide.

And I'm still thinking of this 40MB one-file application which needs to
be written. 🙂
even the new simple radiance converter has 80MB nowadays.

But not so with visual lisp r14 arx files with thousands of users with
multiple arx files.
--
Reini Urban
http://xarch.tu-graz.ac.at/autocad/news/faq/autolisp.html
0 Likes