Osnaps on when no command active.
I use a script to turn on osnaps:
[code](defun c:son ()
(setvar "osmode" 47)
)[/code] This is used for lisp routines and other macros that were previously written that turn off osnaps the crash or don't turn them back on when exiting. Anyway, it seems that if my snaps get turned off, and I then use my script above to turn them on, when I hover around the screen with the cursor, sometimes the snaps pick up on objects when no command is running. has anybody else noticed this in V12.1.8?
0
Comments
-
Hi Scott,
Can't say that I have seen your issue, but in terms of cancelling lisp routines you could try using an error handler to automatically reset your OSMODE. example below
[code](defun *error* (er)
(setq MyOsmode 47) ; My Osnap Settings
; Determine the error type, and react accordingly
(cond ((eq er "console break") (setvar "osmode" MyOsmode))
((eq er "Function cancelled") (setvar "osmode" MyOsmode))
((eq er ())(setvar "osmode" MyOsmode)) ; Error not stated
(T (princ (strcat "ERROR: " er )) (setvar "osmode" MyOsmode)) ; Print the error otherwise
)
(prin1) ; make a quiet exit
)[/code]
You would place the above code into your on_doc_load.lsp
Regards,Jason Bourhill
0
This discussion has been closed.