PDA

View Full Version : Autolisp for custom blocks.



cadsultant
7th Apr 2005, 12:15 am
I am working with a lot of 3d deck drawings (ACAD2k5). The railings which go on these decks are all different sizes. Sizes for railing sections are for example 45", 46.5", 48", etc. In other words, there is no standard size. I am creating a bunch of blocks varying in size, and inserting them through tool pallettes. But I am constantly having to recreate new sections. :?

For instance two vertical 1.5" posts, one at each end, then two horizontal 1.5" pipes, one at top one at bottom, creating a section of railing. Is it possible to create a lisp routine that will create different size railings (the horizontal members are the only ones that would change)? So if I entered 66.5", then it would insert the two 66.5" long sections of railing, one at top, one at bottom.

I studied some autolisp a few versions back, but I have forgotten most of the little bit that I knew, so this is way over my head. I would appreciate any help anyone can offer me. Thanks.

David Bethel
7th Apr 2005, 02:53 am
Absolutely!

That is what made ACAD the best product of it's time early on. Parametric routines based in Autolisp.

They kind of let the cat out the bag and are regretting it because they aren't the ones making money out of it. Adesk is totally oreinted towards money now, not inovation. Same as Mr. Gates.

With a little time and effort, you can produce some the complex and complete
models with exacting rules. -David

hendie
8th Apr 2005, 08:24 am
this would be a good project for VBA.
You could set up a nice dialogue to prompt for the required values and then have it create the full railing set for you.
It is also possible in Lisp but the dialogue would be a real pain to create.

If this is something you do a lot it would be worth investing the time in it and getting it to do as much as possible for you ~ i.e. creating a Bill of Materials etc