Hello, AutoCAD community,
The AutoCAD team wants to hear your impressions of AutoLISP, specifically around its availability in the 2024 release of AutoCAD LT.
Which routines are you most excited to use? Let us know in the comments below!

Jonathan Hand
Industry Community Manager | AEC (Architecture & Building)
Jonathan,
It would be nice to outline what functions work and those that do not.
Lisp, ACET, VL, VLA, VLAX, VLR, etc.
Access to the registry and dictionaries.
We do not use .net here.
We do not bundle (though it is a thought).
I do not use the built in editor for LSP or DCL.
I would like to be able to FAS some of my work.
Half of my library involves editing and the other half creating objects.
Programming started back with Release 12 (not R2012).
"Bonus Utilities" was the Express back then and I had all of that
covered with my own utilities. At last count I have over 180 developed
keyboard commands.
We require only a simple 2-D graphic editor, not weighed down with
texture or symbol libraries. I have developed our own "vertical"
menu system that is pretty lean as compared to what I have seen
on this forum, yet more robust than what any type of express tools
can offer - tailored to our environment to produce documents our
clients need to get thru the permit office.
Yes I am interested hearing more about LISP support in LT
and the price comparison to the full-on rented software that
have tools we will never use.
Scot-65
A gift of extraordinary Common Sense does not require an Acronym Suffix to be added to my given name.![]()
AutoLISP has been a valuable tool in the AutoCAD environment for many years, and its inclusion in AutoCAD LT 2024 is a welcome development. AutoLISP is a scripting language that allows users to automate tasks and create custom commands in AutoCAD.
I'm trying to get my programming working with the LT version. I've got a few commands working. But I also need to be able to load Doslib. Do you know if this should be possible?
DOSlib is ARX-based, so no chance in AutoCAD LT. On the other hand, most apps are working fine without any dependency on DOSlib.
Vladimir Michl, www.arkance-systems.cz - www.cadforum.cz
Isn't there any way this can be made possible? Or solved with a workaround?
I can see mostly msgbox, date functions - all this can be done also without doslib. With a little bit more overhead but compatible with future versions, without any external dependencies.
Vladimir Michl, www.arkance-systems.cz - www.cadforum.cz
Can you perhaps point me a function that could replace the dos_msgbox function?
Yes, either a DCL dialog, the (alert) function, or something like (the ":" means ":"):
(startapp (strcat "mshta.exe vbscript:close(CreateObject(\"WScript.Shell\").Popup(\"HELLO WORLD\",4,\"TITLE\",1))"))
Vladimir Michl, www.arkance-systems.cz - www.cadforum.cz
I used this one for a long time, now I replace doslib with lisp functions written in .net (c#).
Note that you must have the VBA add-on installed, just realized that, so not sure if LT has that available.
BTW, acad is like $1500 a year, and bricscad pro is about 1/2 that, and both have full lisp, arx, and .net.
If a business cannot pay that, they have bigger problems than not using automation.
You may be in a situation with low revenue, or employers that spend dollars to save nickels, and that's a challenge.
;;;ConstantS
;;;vbOKOnly 0 Display OK button only.
;;;vbOKCancel 1 Display OK and Cancel buttons.
;;;vbAbortRetryIgnore 2 Display Abort, Retry, and Ignore buttons.
;;;vbYesNoCancel 3 Display Yes, No, and Cancel buttons.
;;;vbYesNo 4 Display Yes and No buttons.
;;;vbRetryCancel 5 Display Retry and Cancel buttons.
;;;vbCritical 16 Display Critical Message icon.
;;;vbQuestion 32 Display Warning Query icon.
;;;vbExclamation 48 Display Warning Message icon.
;;;vbInformation 64 Display Information Message icon.
;;;vbDefaultButton1 0 First button is default.
;;;vbDefaultButton2 256 Second button is default.
;;;vbDefaultButton3 512 Third button is default.
;;;vbDefaultButton4 768 Fourth button is default.
;;;vbApplicationModal 0 Application modal; the user must respond to the message box before continuing work in the current application.
;;;vbSystemModal 4096 System modal; all applications are suspended until the user responds to the message box.
;;;vbMsgBoxHelpButton 16384 Adds Help button to the message box
;;;VbMsgBoxSetForeground 65536 Specifies the message box window as the foreground window
;;;vbMsgBoxRight 524288 Text is right aligned
;;;vbMsgBoxRtlReading 1048576 Specifies text should appear as right-to-left reading on Hebrew and Arabic systems
;(Msgbox '("Do you want to continue ?" 3 "MsgBox Demonstration" "DEMO.HLP" 1000))
;(Msgbox '("File Exists, Overwrite?" 4 "File Question" NIL NIL))
;(Msgbox '("Choose Option" 4 "File Question" NIL NIL))
(defun Msgbox (ArgLst / Msg Style Title Helpfn Ctxt oldUseri5 RetVal)
;DO ON COMMAND LINE FOR 64 BIT SYSTEMS
(mapcar 'set (list 'Msg 'Style 'Title 'Helpfn 'Ctxt) ArgLst)
(setq oldUseri5 (getvar "USERI5"))
(vla-eval
(vlax-get-acad-object)
(strcat "ThisDrawing.setVariable \"USERI5\" ,CInt((MsgBox(\""
Msg "\""
(if Style (strcat "," (itoa Style)) "")
(if Title (strcat ",\"" Title "\"") "")
(if Helpfn (strcat ",\"" Helpfn "\"") "")
(if Ctxt (strcat "," (itoa Ctxt)) "")
")))"
)
)
(setq RetVal (getvar "USERI5"))
(setvar "USERI5" oldUseri5)
RetVal
)
that is calling the vba dialog. The top part has a few examples of its use.
internal protected virtual unsafe Human() : mostlyHarmless
I'm just here for the Shelties
The principle is similar but the calling mechanism is different. AutoCAD LT doesn't support VBA, so you cannot use your method with 'eval'. The above 'startapp' example uses Windows mechanism to run the VBscript code, no VBA. The only problem remains the return value.
Vladimir Michl, www.arkance-systems.cz - www.cadforum.cz
I wouldn't want to spend my time programming something that already might be available.
To start with... I can imagine there could already be a lisp routine out there that can replace the Doslib function
(dos_msgbox text title button icon [duration]) I'm a bit rusty : ) I have written my lisp routines over a decade ago.
Yes, there is - see e.g.:
https://www.cadforum.cz/en/universal-msgbox-in-autolisp-tip14006
Vladimir Michl, www.arkance-systems.cz - www.cadforum.cz
Another
(defun MsgBox (title buttons message time / return WshShell)
(setq WshShell (vlax-create-object "WScript.Shell"))
(setq return (vlax-invoke
WshShell
'Popup
message
time
title
(itoa buttons)
))
(vlax-release-object WshShell)
return
)
(MsgBox "Hello world!" 0 "Welcome\nthe world is still spinning\naround and around" 4)
You can make slides and display them also using Vslide and a delay. This way can have pretty pictures.
The result of selecting a button in the post bu Vladimir is always 0? Then I cannot use the result with an if statement.
I do get different result values with the defun post by Sea-Haeven.
Where can I find out which value represents which buttons to be displayed?
Yes, the full AutoCAD's LISP can use (vlax-create-object) so the Sea-Haeven's implementation is possible. But this thread is about the LT limitations. And without that function, you cannot use this such implementation. The return value is a problem and the solution would be much more complicated.
Vladimir Michl, www.arkance-systems.cz - www.cadforum.cz
You are correct I guess. I'm getting "bad argument type: stringp nil" in AutoCAD LT
Why is it that the return value is a problem. Is that because it's returned from outside the lisp interpretor or something? Then maybe I need to solve it with the AutoLISP Message Box | AfraLISP option.
Can't find what you're looking for? Ask the community or share your knowledge.