Here you will find useful information for those who want to learn AutoLISP but unable to find resources, or those who want to advance to next level in using AutoCAD. This page is prepared as a resource for AutoCAD programmers and a place for everone to share information.
______________________________________________________________
Beginners
______________________________________________________________
- Introduction to AutoLISP: My first AutoLISP program…
- Introduction to AutoLISP
- A simple AutoLISP program
- My first AutoLISP program
- Programming with Visual LISP editor…
- Get organized
- Console window for more than one drawing
- Using console short-cuts
- Keeping console window log
- Using the text editor
- Color coding
- Write your code understandable
- Expressions, variables and data types
- AutoLISP Data Types
- AutoLISP Variables
- Watching the value of a variable
- Pre-defined variables
- AutoLISP (command ..) function
- Foreign Language Support
- Pausing for the user to enter data
- Passing (PICK POINTS) into (command) function
- Parametric design with Autolisp
- Introduction
- Advantages and disadvantages of using blocks
- Autolisp programming language
- A simple parametric design program
________________________________________________________
Intermediate
________________________________________________________
- User input functions
- (getint) and (getreal) functions
- Angle input with (getangle)
- Get the other corner by (getcorner)
- Rectangle.lsp application
- Getting distance by (getdist)
- Prompting user to enter a keyword by (getkword)
- Prompting user to pick a point (getpoint)
- Prompting user to enter a string (getstring)
- Managing Lists in AutoLISP (List Handling)
- Point Lists
- Rectangle.lsp
- Dotted pairs
- Entity lists
- Data search in lists
- Loading AutoLISP applications automatically
- MDI Interface
- Application Level
- Document Level
- Automatic Load
- Loading with menu
- Defining our own functions
- (defun …) Defining a new function
- Definition and usage of functions with arguments
- Local variables that are used inside the functions
- Changing AutoCAD commands (redefining)
________________________________________________________
Advanced
________________________________________________________
- Selection sets in AutoLISP programs
- Creating a new selection set by using (ssget)
- Manipulating a selection set
- Iterating though entities inside the selection set (ssname)
- Removing entities from selection set
- Filtering selection set
- DXF Codes
- Objects and Entities
- Group Code Values
- Description of Group Codes
- DXF Group Codes of the Most Common AutoCAD entities
- General Structure of a DXF file
- A sample DXF file
- Using entmake function to add entities to drawing
- Drawing LINE by using entmake
- Drawing CIRCLE by using entmake
- Creating MTEXT by using entmake
- Creating a LWPOLYLINE by using entmake
- Adding a new LAYER into the LAYER table by using entmake
- DXF Group Codes
- Drawing Database
- Managing basic file operations in AutoLISP
- File Pointer
- Openig a file
- Reading lines from file
- Writing lines into a file
- Closing open files
- Error handling in AutoLISP 1
- (*error* errtxt) function
- TEST programme
- Error hadling in AutoLISP 2
- (alert …) function
- (exit) function
- (quit) function
- Command aliases in AutoCAD
- Programming dialog boxes in AutoLISP: DCL
- Protecting your code
________________________________________________________
Sample Programs
________________________________________________________
- Defining user function
- entsel, entget, car, cadr and cdr functions
- Using (command function)
- Declaring local variables
- entsel, entget, car, cadr and cdr functions
- Checking entity type
- Changing system variables
- entsel, entget, car and cdr functions
- Creating selection set with ssget
- selection set filtering
- Walking trough selection sets
- String manuplation techniques
- Defining user functions
- Giving options to user
- Defining user functions
- Managing ATTRIBUTES in blocks
- Managing options in DYNAMIC BLOCKS
- Prompting user for selection
- Waiting user (pause)
- Using (getvar) function
- Reading lines from text file
- List operations
- Entmake function
- while loop
- string operations
- Building point lists
- Datatype conversions
- Mathematical functions
______________________________________________________________
Articles
______________________________________________________________
Total: 6474
This week: 314
Today: 18
Last read: 11 October 2008, 11:17