TheSwamp
Code Red => AutoLISP (Vanilla / Visual) => Topic started by: mohan on November 25, 2021, 03:57:09 AM
-
Code fixing please
Block Name: "A$C1A300073"
(defun c:blockfind ( / ss )
(vl-some '(lambda (layout)
(if (setq ss (ssget "X" (list (cons 2 "A$C1A300073") (cons 67 1) (cons 410 layout))))
(list ss layout)))
(layoutlist)) (princ))
-
It's likely easier to approach it this way:
(if (setq s
(ssget "_X" '
((0 .
"INSERT") (2 .
"A$C1A300073")))) (princ "\nBlock not found.") )
)
-
Your codes search only in Paper spaces so you need to bring the result from the vl-some function out to publicity to know the outcome. :grinwink:
(defun c:blockfind
(/ ss lst
) )
)
)
)
)
)
lst
)
-
It's likely easier to approach it this way:
Your codes search only in Paper spaces so you need to bring the result from the vl-some function out to publicity to know the outcome. :grinwink:
Thank you so much . . . :smitten: