- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Hi,
I am currently attempting to write some LISP code to carry out the -OVERKILL, -PURGE, AUDIT and SPELL commands in this specific order in an attempt to make an easy way to clean up drawings in AutoCAD 2023.
Unfortunately, I am having some issues with the -OVERKILL command, specifically simulating the enter key after object selection. I have attempted to use " " and ";" to no effect.
If anyone has any tips on how to get this to work that would be great! I have copied my attempt at coding this below for anyone to check out.
Thank you!
(defun c:CLEANUP ( / )
(princ "\nStarting drawing cleanup...")
(command "-OVERKILL" "ALL" ";" "D")
(princ "\nNo objects to clean with OVERKILL.")
(command "-PURGE" "ALL" "*" "N")
(command "AUDIT" "Y")
(command "SPELL")
(princ "\nCleanup complete.")
(princ)
)
Solved! Go to Solution.