Jump to content

Material Bubs


bonehead_96

Recommended Posts

Need Help please!!

I am getting an error message "error: no function definition: ACET-SS-DRAG-MOVE" using the attached Lisp after installing AutoCad 2025.  I have used this lisp in previous version with no issues.

It's probably something simple, but I can't find it.

MatBubb1.lsp HMatbub.dwg

Link to comment
Share on other sites

Looks like an exress tool - did you install them as well with 2025?

Link to comment
Share on other sites

Thanks for looking

Yes, express tools is loaded

I think I have found the problem.  for some reason "acetutil.arx " is/was not loaded.  I added it to load in the startup suite and the lisp is working.

Is there a reason you can think of that "acetutil.arx" would have not been loaded?

 

Link to comment
Share on other sites

Posted (edited)

FYI

 

(setq curosap (getvar "osmode"))
(setq cudragmode (getvar "dragmode"))
(setq olsnap (getvar "SNAPSTYL"))
(setq oortho (getvar "orthomode"))
(setq oattdia (getvar "attdia"))
(setq oattreq (getvar "attreq"))
(setq odimsc (getvar "dimscale"))
(setvar "orthomode" 0) 
(setvar "osmode" 545)
(setvar "cmdecho" 1)
(setvar "snapstyl" 0)
(setvar "dimscale" 1)
(setvar "attdia" 1)
(setvar "attreq" 1)
....
(setvar "osmode" curosap)
(setvar "dragmode" cudragmode)
(setvar "snapstyl" olsnap)
(setvar "orthomode" oortho)
(setvar "dimscale" odimsc)
(setvar "attdia" oattdia)
(setvar "attreq" oattreq)


Can be condensed down to the following

(setq vars '(osmode dragmode snapstyl orthomode attdia attreq dimscale MENUECHO CMDECHO)   ;list of variables you want to capture/set while in lisp
      vals (mapcar 'getvar vars)                                                           ;store old values in a list vals will look like the list below
)
    
(mapcar 'setvar vars '(545 2 1 0 1 1 1 1 1))                                     ;set new values

...

(mapcar 'setvar vars vals)                                                   ;restore old values
Edited by mhupp
Link to comment
Share on other sites

14 hours ago, bonehead_96 said:

Thanks for looking

Yes, express tools is loaded

I think I have found the problem.  for some reason "acetutil.arx " is/was not loaded.  I added it to load in the startup suite and the lisp is working.

Is there a reason you can think of that "acetutil.arx" would have not been loaded?

With AutoCAD 2025, they changed the Express tools to Demand loading, so if a ET function has not been run, then it won't be loaded.

 

Here is a function I use to make sure it gets loaded:

;|==============================================================================
  Function Name: (pjk-ExpressToolsLoad)
  Arguments: None

  Returns: Nothing
  Description:
     This Subroutine Loads Express Tools if not loaded, and alerts the user if
     Express Tools is not installed.
================================================================================|;
(defun pjk-ExpressToolsLoad ()
   (if (not (acet-util-ver))
      (if (findfile "acetutil.arx")
         (arxload "acetutil.arx" "\nError - AutoCAD Express Tools Utilities not loaded")
         (Alert
            (strcat
               "\nAutoCAD Express Tools is Needed for this Function.\nInstall the"
               "AutoCAD express tools from the original product install package."
            )
         )
      )
   )
) ;; End Function (pjk-ExpressToolsLoad)

 

Link to comment
Share on other sites

Thanks

 I guess the "On Demand Loading" works for some people, but it sure is a pain for some too.

 

Thanks again

  • Like 1
Link to comment
Share on other sites

I've just switched all my lisps over to on demand loading, it speeds things up on drawing opening. Biggest hassle is to add new LISPs to the on demand loading file, but once done it is no hassle. I'll probably end up with a 50-50 mix of on demand and pre-loading LISPs.

 

I have a file with the following formated LISPs in, if this routine is called then it loads the relevant file, and then runs the LISP. If the LISP is loaded then usually is is loaded after this file and will run as normal without going through the load (latest loading of the LISP is the one that runs)

 

(defun c:3PARC ( / )
  (load "C:\\Users\\SP\\Desktop\\AutoCAD\\AutoCAD LISPS\\LinesToArc.lsp") (c:3PARC) (princ) ;;LISP File / Run LISP
)

 

 

Could be modified to:

 

(defun acet-ss-drag-move ( ss pt Prompt1 Prompt2  / )
  (if (findfile "acetutil.arx")
    (progn (arxload "acetutil.arx" "\nError - AutoCAD Express Tools Utilities not loaded") (acet-ss-drag-move ss pt Prompt1 Prompt2) )
    (Alert "\nAutoCAD Express Tools is Needed for this Function.\nInstall the AutoCAD express tools from the original product install package.")
  )
  (princ)
)

 

Have this file load on start up

  • Like 1
Link to comment
Share on other sites

Do you use Autoload function ?

 

(autoload "COPY0" '("COPY0"))
(autoload "COPYCOMMAND" '("ZZZ"))
(autoload "COVER" '("COVER"))
(autoload "DIMFLIP" '("DIMFLIP"))
(autoload "DRAWXFALL" '("DRAWXFALL"))

 

 

  • Agree 1
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...