Jump to content

Recommended Posts

Posted

how do i create a lisp routine do i need any special program and how do i use it in autocad

do i need to save the file to a specific place?

i want to learn to create it so i can speed up my drawing

i currently have a drawing with about 100 lines all starting the same place and heading out from there..

Posted

Hi Mathew21 - Welcome to CADTutor :)

 

I would suggest that you head over to AfraLISP or JeffreySanders and check out the Beginners Tutorials to get you started with LISP.

 

I would strongly recommend that you write your programs using the Visual LISP Editor provided with AutoCAD - this will provide all the help documentation you will need and also provides great debugging facilities. To get started with the Visual LISP Editor, see my tutorial here, and you might be interested in a few other tutorials here.

 

Good luck!

 

Lee

Posted

Welcome to the forums!

 

There are many resources on this topic... Here's one:

 

Within AutoCAD, type VLIDE and hit enter. This will open the Visual LISP Integrated Development Environment (VLIDE). Within the VLIDE, hit F1 for the Developer Documentation, and see the 'AutoLISP Tutorial' as a starting point.

 

dev_doc.png

Posted

thanks muchly.. fast response and ill take a look

Posted

ok.. ive read the things and think what im wanting is beyond me for now.. bacially what i want to do is draw a line from point A to point B then another from point B to C then to start over agian but go from point A to point D then to point E

does anyone think they can help me?..

i was able to figure out 1/2 of what i wanted.. i can start lines from point a to b then a to c but cant go from point b to c

Posted
ok.. ive read the things and think what im wanting is beyond me for now.. bacially what i want to do is draw a line from point A to point B then another from point B to C then to start over agian but go from point A to point D then to point E

does anyone think they can help me?..

i was able to figure out 1/2 of what i wanted.. i can start lines from point a to b then a to c but cant go from point b to c

 

Dude... you won't learn it in 10 minutes - it'll take weeks and weeks of coding and practice, you've got to put some effort in to get something out.

Posted

nvm got it.. does dynamic imput work during lisp commands? or ortho?

Posted

ok thanks muchly.. damm gotta figure out where i went wrong then.. the thing i designed works but it doent follow ortho or @ cords.

Posted

Sounds like you need to master the Polar command it calculates a new pt based on a starting point, a length and an angle. A box would then become join 4 pts (command "line" pt1 pt2 pt3 pt4 "C")

 

A big hint the angles are always in radians irrespective of what your "units" are set to so 0degs = 0.0 90degs = 1.5708 180degs= 3.1416 & 270degs=4.712 this is the same as ortho on.

Posted

yep only thing that i cant figure out is how to imput the sizes in afterwords.. i need the sets of lines to be differnt lengths but i want angle to stay the same.. is there some way that you can preset the angle and then enter the length afterwords

polar has always been kinda week for me.. i understand it just can never remember how to enter cords properly

Posted

Store your needed angle to a variable (perhaps named ANG?), then simply reference that variable as needed.

Posted

Look in help for AutoCAD and search on CADTutor for Creating Script files.

Posted

how do i get the line to draw along that angle?

or does anyone know of a tutorial that helps draw lines better?

i can get points to work but there a fixed location so everytime they come out in the same spot

Posted

ok thanks for all your help.. i got it.. i reread everything and used info u gave me and i figured out i was useing wrong command.. getpoint not getdist

changed and added it as veriable and got it to work..

workd fine now so thanks

tested it with everything i can think of and it works..

i can post if anyone wants.. im gonna use it for ploting locations that i had to measure (tape measure X Y and right angle triangle)

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