Message 1 of 8
Thicken all surfaces inside block definition
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Hello
I want my lisp to modify all the surfaces in the block definition so that those blocks are thickened by fixed value 0.001
My current attemp is below
(defun c:test2 ( / s )
(princ "\nSelect Block: ")
(if (setq s (ssget "_+.:E:S" '((0 . "INSERT"))))
(LM:ApplytoBlockObjects
(vla-get-blocks (vla-get-activedocument (vlax-get-acad-object)))
(vla-get-effectivename (vlax-ename->vla-object (ssname s 0)))
'(lambda ( obj ) (command "_thicken" obj "0.01"))
)
)
(princ)
)
(vl-load-com) (princ)
(defun LM:ApplytoBlockObjects ( blks name func / def result )
(setq func (eval func))
(if (not (vl-catch-all-error-p (setq def (vl-catch-all-apply 'vla-item (list blks name)))))
(vlax-for obj def
(if (= (vlax-get-property obj 'ObjectName) "AcDbSurface")
(setq result (cons (func obj) result))
)
(princ (vlax-get-property obj 'ObjectName))
)
)
(reverse result)
)