Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 07/26/2023 in all areas

  1. @mhupp How about ODBX do not accept ? Other topic , about wildcard. as I can see ~ means all but not, please refer where to see all other wildcards uses
    1 point
  2. This will select everything in the drawing except things on the cut layer& delete them. to feed to ODBX (defun Delete-all-Cut (/ SS) (setq ss (ssget "_X" '((8 . "~Cut")))); select everything in the drawing except whats on the cut layer. (foreach ent (mapcar 'cadr (ssnamex ss))) (entdel ent) ;delete everything ) (repeat 3 (vl-cmdf "_.Purge" "A" "*" "N")) ;purge 3 times. ) Now if their are blocks on the cut layer that have entities inside them on another layer those won't be deleted.
    1 point
  3. This was an example, I thought it was simple for you to interpret this one and modify it accordingly. Without knowing your lisps, then maybe like this? (defun c:FOO ( / ) (if (not (c:xx)) (load "xx.lsp")) (if (not (c:yy)) (load "yy.lsp")) (mapcar '(lambda (x) (cond ((and (not (zerop (atoi x))) (eq (atof x) (atoi x))) (if (zerop (rem (atoi x) 2)) (c:xx) (c:yy) ) ) (T (princ (strcat "\nThe layout \"" x "\" have not name with interger or is null"))) ) ) (layoutlist) ) (textscr) (prin1) )
    1 point
  4. Try Exceeds with this small change (not fully checked but it should work): From: (if (= (len (atoi cl)) (len (itoa (atoi cl)))) ; check if the layout string is numeric. To: (if (= CL (itoa (atoi CL))) ; check if the layout string is numeric.
    1 point
  5. Don't use (atof) for distance-final before use (vl-string-subst). It do not replace for the real number
    1 point
×
×
  • Create New...