Certain custom Autolisp Routines quit working in AutoCAD 2025 error: no function definition: acet-ui-message

Certain custom Autolisp Routines quit working in AutoCAD 2025 error: no function definition: acet-ui-message

Sean.Boseman
Participant Participant
5,545 Views
18 Replies
Message 1 of 19

Certain custom Autolisp Routines quit working in AutoCAD 2025 error: no function definition: acet-ui-message

Sean.Boseman
Participant
Participant

Hello, I've been using a couple custom lisp routines for several years now that appear to not work in AutoCAD 2025, yet they've worked in all previous versions. I have both 2024 and 2025 installed and the routines still work perfectly on 2024, but in 2025 I receive the message "error: no function definition: acet-ui-message". Will ask you whether you want to plot to the printer and if so, ask how many copies and will proceed to print to our particular printer. If you say no, it will just change the current drawing's plot settings to our desired settings. Does anyone one know why all of a sudden the long used lisp routine stopped working for AutoCAD 2025? is this just a bug? See below copy of the program, I've also attached the file. I appreciate the help in advance.

 

(defun c:isg (/ a k qty)
(setq k (acet-ui-message "Do you really want to print a color copy to the ISG Printer?" "Print Confirmation:" 52))
(if (= k 6)
(progn
(setq qty nil)
(setq qty (getreal "\nEnter number of copies <1>:"))
(if (= qty nil) (setq qty 1))
(setvar "cmdecho" 0)
(setq a (getvar "tilemode"))
(while (/= qty 0)
(progn
(if (= a 0)
(command "-plot" "y" "" "\\\\print\\SALES_KM_C558" "11x17" "inches" "landscape" "no" "extents" "fit" "center" "no" "" "yes" "no" "no" "no" "no" "yes" "yes")
(command "-plot" "y" "" "\\\\print\\SALES_KM_C558" "11x17" "inches" "landscape" "no" "extents" "fit" "center" "no" "" "yes" "as" "no" "yes" "yes")
)
(command)
(setq qty (- qty 1))
)
)
)
(progn
(setvar "cmdecho" 0)
(setq a (getvar "tilemode"))
(if (= a 0)
(command "-plot" "y" "" "\\\\print\\SALES_KM_C558" "11x17" "inches" "landscape" "no" "extents" "fit" "center" "no" "" "yes" "no" "no" "no" "no" "yes" "no")
(command "-plot" "y" "" "\\\\print\\SALES_KM_C558" "11x17" "inches" "landscape" "no" "extents" "fit" "center" "no" "" "yes" "as" "no" "yes" "no")
)
(command)
)
)
(princ)
)

0 Likes
Accepted solutions (1)
5,546 Views
18 Replies
Replies (18)
Message 2 of 19

CLL_PBE
Contributor
Contributor

acet-ui-message is an Express Tools function that displays a message box.

Perhaps check if you have Express Tool installed for 2025?

 

 

 

 

0 Likes
Message 3 of 19

Sean.Boseman
Participant
Participant

Express Tool does appear to be installed for 2025.

0 Likes
Message 4 of 19

pendean
Community Legend
Community Legend

@Sean.Boseman wrote:

Express Tool does appear to be installed for 2025.


try running a couple of Express tools (start to finish), if they work fine, try your LISP again.

Message 5 of 19

Sean.Boseman
Participant
Participant

Wow, that seems to work! Any idea why I have to run an express tool for the routine to work? I've never had that happen before in subsequent AutoCAD versions. Is this some sort of glitch with 2025?

Message 6 of 19

pendean
Community Legend
Community Legend

@Sean.Boseman wrote:

Wow, that seems to work!...


pendean_0-1714741460497.png

 

Message 7 of 19

Sean.Boseman
Participant
Participant

The value appeared to be already set to 3.

Message 8 of 19

komondormrex
Mentor
Mentor
Accepted solution

Is this some sort of glitch with 2025?

it seems so. add this expression (load "acetutil") at the beginning of your code.

Message 9 of 19

Sean.Boseman
Participant
Participant

excellent, that worked! Thank you!

0 Likes
Message 10 of 19

ВeekeeCZ
Consultant
Consultant

AutoCAD 2025 does not preload express tools automatically anymore. They wanted to speed up the application startup. So now there is a new function. It works similarly to vl-load-com.

 

(acet-load-expresstools)

 

See HELP 

Message 11 of 19

1wildwes
Collaborator
Collaborator

I've tried inserting that expression before and after the (DEFUN C:XD (/ bl blst ent ans).  There are indentions shown in the attached. Are you able to tell me exactly where to insert the expression? Thanks!

 

(load "acetutil")
(DEFUN C:XD (/ bl blst ent ans)
(setq bl (entsel))
(setq blst (entget (car bl)))
(setq ent (cdr (assoc 0 blst)))
(if (= ent "INSERT")
(progn
(setq xname (cdr (assoc 2 blst)))
(CHKREF)
(if (= check_val 1)

0 Likes
Message 12 of 19

1wildwes
Collaborator
Collaborator

Full lsp attached

0 Likes
Message 13 of 19

pendean
Community Legend
Community Legend

@1wildwes wrote:

Full lsp attached


Use the other tip

pendean_0-1717091340520.png

 

pendean_1-1717091384547.png

 

Seems to work here.

 

0 Likes
Message 14 of 19

komondormrex
Mentor
Mentor

you can put it any place outside any function. but very top is likely to be the best place.

thou did not find any et function in your code.

 

 

0 Likes
Message 15 of 19

rgrainer
Collaborator
Collaborator

first line after defun

0 Likes
Message 16 of 19

btillett
Advocate
Advocate

Seem to need that in 2026 as well.

Boris
0 Likes
Message 17 of 19

Sea-Haven
Mentor
Mentor

Maybe something like this, you can add how many prints to the dcl also.

(defun yesno ( / butval)
(defun butval ( / )
    (if  (= (get_tile "Rb1") "1" )
        (setq colprint "yes")
		(setq colprint "no")
    )
)
(setq dcl (vl-filename-mktemp nil nil ".dcl") )
(setq des (open dcl "w") )
(foreach x 
'(
"yesno : dialog 	{"
"	label =\"Print color copy to ISG Printer\" ;"
"	: row	{"
"	: boxed_radio_row	{"
"	: radio_button	{"
"key = \"Rb1\";"
"label = \"Yes\";"
"	}"
"spacer_1 ;"
"	: radio_button	{"
"key = \"Rb2\";"
"label = \"No\";"
"	}"
"spacer_1 ;"
"	}"
"	}"
"spacer_1 ;"
"	ok_cancel;"
"	}"
)
(write-line x des )
)
(close des)
(setq dcl_id (load_dialog dcl))
(if (not (new_dialog "yesno" dcl_id) )
(exit)
)
(action_tile "accept" "(butval)(done_dialog)")
(action_tile "cancel" "(done_dialog)")
(start_dialog)
(unload_dialog dcl_id)
(vl-file-delete dcl)
(princ )
)

SeaHaven_0-1744852847031.png

 

 

0 Likes
Message 18 of 19

btillett
Advocate
Advocate

Not sure I would add 45 lines of code to replace what can be done with just 2 lines.

But the box looks nice thank you!


;--------------Warning to continue
(load "acetutil")
(if (= (acet-ui-message "You are about to change your layer settings. Ok to proceed?" "pick ok or Cancel" 1) 2)(exit))
;-----------------

e066d634-66f4-4f58-81db-bbd2db373139.png

 

Boris
0 Likes
Message 19 of 19

Sea-Haven
Mentor
Mentor

Ok the short version. 3 lines. The multi radio buttons.lsp is a global program and can be used in any code you want to write. Multi getvals, Multi toggles also, as well as a few more global make dcl's. Just save in a support path. Examples in top of code. It was used to make the dcl code in the lisp.

 

(if (not AH:Butts)(load "Multi radio buttons.lsp"))
(if (= but nil)(setq but 1))
(setq ans (ah:butts but "H"   '("Print color copy to ISG Printer" "Yes" "No" )))

Ans returns "Yes" or "No", a hidden option is variable "but" returns 1 or 2 useful when you have long descriptions. Replace "H" with "V" and a vertical dcl is made.

 

0 Likes