Convertyour drawings (.dwg) into autolisp (.lsp) code. Update: Tested with AutoCAD 2012, it works correctly!
In this New Millennium, drawing smarter using programming created from DansMark is your best competitive edge!
With DansMark Software Solutions,
your only limited by your imagination...
Drawing2lisp_converteris a NEW program from DansMark Software Solutions, to automatically convert drawings into Autolisp programming code.
It's a great way to create your programming, while saving time & money!
This software creates base-code programs of your AutoCAD drawings & details, and can be parametrically linked together to automate your whole drafting process!
Drawing2lisp_converter.lsp can help you convert drafting hours/days/weeks, into seconds/minutes/hours!
Watch the DEMO'S (below) of Drawing2lisp_converter.lsp converting a very complex drawing of a stair system, into multiple functions in an Autolisp program!
Load & run the programming to automatically draw your drawing exactly as it was when converted into programming code!
Seeing is believing! (see video's below)
This program is based on a simple, yet powerful, version of the powerful Draw-'T-Lisp drawing (.dwg) to AutoLisp (.lsp) conversion programming (Option #1).
This "scaled-down" Lite version can convert drawings into programming code faster than you can think!
The "Drawing to .lsp Converter" is a simple conversion tool to help reduce the time it takes to write all the basic "skeleton-code" of the drawing you want to convert to programming code.
Understanding how the program works is essential to success.
All variables are created as "Global".
Just change the variables in the code, then the drawing will Auto-Update itself to any change in the design, instantly!
There are 6 main functions to Drawing2Lisp_converter.lsp
2) Entity Selection
3) Text ID
5) Write to File
There are 2 types of code to write:
This mode overwrites the file "C:\Dansmark\Advanced\Drawing2Lisp_converter\D2LC_Sample-Code.lsp".
All functions and variables are wrote as a "New" file.
This mode is default, and once run, it automatically changes to "Append" mode.
This function Appends (adds) functions and variables to the existing file "D2LC_Sample-Code.lsp".
Once this mode is selected, it will become default for each following function.
2) Entity Selection...
There are 2 modes for conversion:
Auto is the fastest & easiest method to convert drawing entities to code!
The entities that can be converted in both modes are:
Lines, Arcs, Circles, Text, Dimensions, M-Text, Blocks, Hatches, LW-Polylines
There are many ways this modes can be used.
aa) Selecting all entities at once (as many as you want in the current function).
This selection method converts the entities "randomly".
bb) Select each entity as you want them to appear in the code.
This method allows for the best control.
This mode will convert all entities selected to programming code automatically.
This command is selection-sets, this mode allows users to add and remove entities to the
selection-set. Also, users can zoom and pan while in the selection-set process.
(see AutoCAD's help on selection-sets).
Pro Hint: Select each entity as you want them to appear in the programming-code.
Make sure you are where you want to be in the drawing when you finish selecting
the entities to convert (pan & zoom), this just makes it easier to remember what you want
to do next.
This mode allows the user to decide which entity type to select and convert to code.
Entity type: SHIFT+ <1>=LINE, <2>=ARC, <3>=CIRCLE, <4>=LWPLOYLINE, <5>=DIM,
<6>=INSERT, <7>=HATCH, <8>=TEXT, <9>=POINT, <0>=Mtext, <->=LEADER
Pro Hint: Use the Shift+Number to create the code for the entity selected (you will be
prompted for the entity to be converted into programming code. Warning... Make sure it's
the correct entity-type).
3) Text ID...
With/Without Text mode:
This option adds a color-coded "number" text-entity to the code, so the user can find
which code-segment coincides with which entity. When the program is run, a number is
placed at the "start" of each entity in the drawing. To find where the entity is in the code,
just search for the coinciding number.
(The text-height is 0.0312, so look closely)
Line=2, Arc=5, Insert=4, Leader=2, M-text=6, Circle=3, LW-polyline=4, Hatch=8, Point=3, Dimension=7
Example: Search for text "32" in Visual Lisp (must be a text item searched for) will take you to the
end of the code where the entity creation code is used (see the http://dansmark.com website for examples).
This is the default.
No color-coded "number" text-entity is placed in the code.
The combination of both "Name & Number" is the name of the function name.
The name is the 1st part of the name (prefix), and the number is the second (suffix).
The number you pick is 1- of the number used in the function.
(If you want each function-name to end with a 1, pick 0 each time)
This is the prefix of the function-name.
You can use any name you want, but don't use the "-" in the name, as this will cause an error, and the
results could crash the program.
If the program crashes you must re-open the drawing to reset the program.
The is the suffix of the function-name.
The program adds 1+ automatically so the name can stay the same without having conflicting functions.
Users can use the same number over and over by changing the "Name", but beware of conflicts in your code.
There is a running variable-number throughout the use of the program.
As each entity is converted into code, the program adds a 1+ to the running total (which is the variable count).
PT0, PT1, PT2...
5) Write To File...
There are 2 modes in this option.
Append is default.
Once you have converted all the entities you want, then pick the Finalize check-box to finish the code and write
The is the default while converting entities to code.
All additional functions will be appended to the file.
This mode finishes the file and creates the Master-Function to control all the available functions.
The help system describes what each option does.
Pick a function, then pick the "Help" button to display an explanation of the option.
The help will display the "last" option picked.
What the program does:
When the user selects the entities for conversion, the programming code is captured and saved.
Each time the user exits the selection-set mode (and returns to the dialog), the program creates a function for all the entities in the current selection-set.
These functions are saved and added to a master-list until the "Finalize" button is selected, (The "Finalize" button ends the conversion process for that drawing. Close the drawing and re-open to convert entities again).
For each 100 entities that are converted, it takes approx. 1-5 seconds (depending on what options are selected) for the program to finish converting them. Approx. 80-100 lines of code is created for those 100 entities.
(The amount of code created also depends on what type of entities are converted and options that are used)
Imagine writing 12,000 lines of code in under 30 seconds!
With DansMark Software Solutions,
your only limited by your imagination...
These are video demo's of Drawing2lisp_converter.lsp converting a stair drawing into Autolisp code.
Demo-2: Options explained
Demo-3: Walls & 1st Stringer
Demo-4: 2nd Stringer
Demo-5: 3rd Stringer
Demo-6: 4th Stringer
As A Bonus:
The program that was wrote during these videos will be part of the installation package!
You can run this program as a stand-alone, or as part of the "Demo Mode" before registering!
This will give you a good idea of the power of Drawing2Lisp_Converter.lsp!!
(Note: Drawing2Lisp_Converter.lsp MUST be run in the provided drawing Stair_test.dwg!)
Demo-8: Loading The Menu
Demo-9: Youtube Intoduction
Free downloadable Drawing2Lisp_Converter.lsp
(See "Free Download" at left-side)
1) Download the Download Drawing2Lisp_Converter_SetupKit.zip file, then un-zip it to any directory you choose.
2) Run Drawing2Lisp_Converter_SetupKit.EXE, this will install Drawing2Lisp_Converter.lsp, and associated files, to their final destination.
3) Open C:\Dansmark\Advanced\Drawing2Lisp_converter\, then run Setup_Drawing2Lisp_Converter.EXE (this is the .exe program that has the .lsp in it).
Make sure to install to the default directory!
Any other directory will result in errors when trying to run Drawing2Lisp_Converter.lsp!
4) Open AutoCAD (tested with 2000-2007), and use the appload command to find Drawing2Lisp_converter.lsp and load it.
5) Type D2LC to execute Drawing2Lisp_Converter.lsp
6) You will have to register the program in order to use it (just protecting my hard work, and I want to know who is using it).
I have provided D2LC_Sample-Code_Stairs.lsp for free, so you can see what Drawing2Lisp_Converter.lsp can do.
(you MUST run D2LC_Sample-Code_Stairs.lsp in the Stair_test.dwg)
7) Click the Demo Mode button to run D2LC_Sample-Code_Stairs.lsp in the Stair_test.dwg
You must register your version of Drawing2Lisp_converter.lsp to use it.
Convert your drawing into AutoLisp code, in seconds.
Easy to use
Exact copy of drawing as an Autolisp program
Easily change variables to adapt to new designs
Easily create full blown programs!