;; | --------------------------------------------------------------------------- ;; | BL_WriteAttrNo ;; | --------------------------------------------------------------------------- ;; | Function : Write a value into a specified attribute at a given position ;; | in a block ;; | Argument : 'ename' - entity name of the block ;; | 'pos' - position of the attribute in the block (from 1) ;; | 'Value' - Value to be updated ;; | Returns : The updated block entity name if succesful otherwise nil ;; | Updated : November 12, 1998 ;; | e-mail : rakesh.rao@4d-technologies.com ;; | Web : www.4d-technologies.com ;; | --------------------------------------------------------------------------- (defun BL_WriteAttrNo ( ename pos value / aname entl ) (setq aname (BL_FindAttrNo ename pos)) ; Search for attribute (if aname (progn (setq entl (entget aname) entl (subst (cons 1 value) (assoc 1 entl) entl) ) (entmod entl) (entupd ename) ) (setq ename nil) ) ename )