Hello,
What I am looking for is a lisp which will report the scale of one particular block within a drawing.
The lisp routine below reports the scale of all blocks within a drawing, I'd like to know how to modify it so that it just reports the scale of single a block called 'PT'.
This block will be in the drawing multiple times but all would be at the same scale.
Thanks
Pads
;;-DISCLAIMER-
;;In no event shall Moss Designs be held liable to anyone for special, collateral, incidental, or consequential damages in connection with
;;or arising out of use of this product. The sole and exclusive liability to Moss Designs shall not exceed the purchase price of the product.
;;Use of the software has been provided under a Software License Agreement.
;;Information described in this software is furnished for information purposes only, is subject to change without notice, and should not be
;;construed as a commitment by Moss Designs. Moss Designs assumes no responsibility or liability for any errors or inaccuracies
;;that may appear in this software.
;;The software contains valuable trade secrets and proprietary information and is protected by United States copyright laws and copyright laws
;;of other countries. Unauthorized use of the software or its documentation can result in civil damages and criminal prosecution.
;;Ver 1.0
;;November 12, 1999
;;Moss Designs
;;www.mossdesigns.com
;;(408) 231-9863
;;21951 Bear Creek Way
;;Los Gatos, CA 95033
;;Contact Elise Moss, Moss Designs
;;elise_moss@techie.com
;;if you have any questions or problems with this software
;;*****************************************************************************************************************************
;;this software lists the blocks in a drawing and their scales
(defun c:bsclist(/)
(setq ssblocks (ssget "X" '((0 . "INSERT"))))
(setq i 0); initialize counter
(setq ssl (sslength ssblocks))
(while (< i ssl)
(progn
(setq en (ssname ssblocks i))
(setq el (entget en))
(setq insert-name (cdr (assoc 2 el)))
(setq xsc (cdr (assoc 41 el)))
(setq ysc (cdr (assoc 42 el)))
(setq line (strcat "BLOCKNAME: " insert-name " X-SCALE: " (rtos xsc) " Y-SCALE: " (rtos ysc)))
(princ line)
(princ "\n")
(setq i (+ 1 i))
));end while
(princ)
);end defun
(princ "\nType 'bsclist' to list blocks and their scales")