Content area
Full text
As a new AutoCAD user, the AutoLISP articles vour journal publishes each month fascinate mi. However, I don't feel comfortable using AutoLISP programs. Could you provide a beginner's guide to AutoLISP?
Suzy Martin
via email
Well, Suzy, you're not alone. We often receive emails from AutoCAD novices who want more information about using AutoLISP programs. We've compiled a selection of AutoLISP basics that you should find useful.
What is AutoLISP?
AutoLISP is based on the common LISP programming language, which is widely used in artificial intelligence applications. As a subset of the LISP language, AutoLISP derives the majority of its functions directly from the LISP language itself. LISP excels at working with lists, which is exactly the type of information used in AutoCAD. LISP is among the easiest of all programming languages to learn.
How can I use AutoLISP?
AutoLISP can be used in three different ways:
1. Type the AutoLISP functions at the AutoCAD command line.
2. Use a text editor, such as Windows Notepad, to create an AutoLISP function or program.
3. Use Windows Explorer to save a program created by another user into the AutoCAD directory and load the program while in AutoCAD.
Using AutoLISP at the command line
AutoLISP has built-in expressions, or functions, that evaluate and return a result. Any AutoLISP expression may be typed at the AutoCAD command line. For example, at the command line, type (+ 2.5 6.5). This AutoLISP function executes the addition of 2.5 and 6.5, and returns the result 9.0
Creating and saving AutoLISP programs
...





