Message 1 of 4
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Hello,
So, I got this wonderful LISP File with whom I can easily rename Blocks just by selecting the Block, and then typing the new name for the block. It works perfectly on my English AutoCAD, but my colleagues have AutoCAD on German, and it doesn't work there. I tried to put German commands to the LISP, but I didn't get it to work. Can someone Help me to modify the LISP for the German AutoCAD?
Thanks in Advance!
;; RB.lsp v1.0 ;; ;; Copyright (c) 1998 by Innovative Programming ;; All Rights Reserved ;; ;; TERMS & AGREEMENT ;; Permission to use, copy, modify, and distribute this software ;; for any purpose and without fee is hereby granted, provided ;; that the above copyright notice appears in all copies and that ;; both copyright notice and this permission notice appears in ;; all supporting documentation. ;; ;; ANY USE OF THIS SOFTWARE IS AT YOUR OWN RISK AND IT IS PROVIDED ;; "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTY. ALL IMPLIED WARRANTIES ;; OF FITNESS FOR ANY PARTICULAR PURPOSE AND OF MERCHANTABILITY ARE ;; HEREBY DISCLAIMED. NO LIABILITY FOR CONSEQUENTIAL DAMAGES. IN NO ;; EVENT SHALL INNOVATIVE PROGRAMMING BE LIABLE FOR INCIDENTAL, ;; INDIRECT, OR CONSEQUENTIAL DAMAGES (INCLUDING, WITHOUT LIMITATION, ;; DAMAGES FOR LOSS OF BUSINESS PROFITS, BUSINESS INTERRUPTION, LOSS ;; OF BUSINESS INFORMATION, OR ANY OTHER PECUNIARY LOSS) AS A RESULT ;; OF THE USE OF OR INABILITY TO USE THIS SOFTWARE. ;; ;; PURPOSE: ;; Rename user selected block. ;; ;; OTHER NOTES: ;; None ;; ;; FUTURE REVISIONS: ;; None ;; ;; REVISIONS: ;; 1.0 9/14/98 Released ;; (defun C:RB (/ SB SBD OLD_NAME NEW_NAME) (setq SB NIL) (while (null SB) (setq SB (entsel "\nSelect block to RENAME: ")) (if SB (progn (setq SB (car SB) SBD (entget SB) ) (if (= (cdr (assoc 0 SBD)) "INSERT") (redraw SB) (progn (redraw SB) (setq SB NIL) (princ "\nItem selected is not a block.") ) ) ) (princ "\nNothing selected. Try again.") ) ) (setq OLD_NAME (cdr (assoc 2 SBD))) (princ (strcat "\n OLD Block Name: " OLD_NAME)) (setq NEW_NAME (getstring "\n NEW Block Name: ")) (command "rename" "b" OLD_NAME NEW_NAME) (princ (strcat "\n BLOCK RENAMED TO: " NEW_NAME)) (princ) ) (princ "\nRBLOCK Loaded. Type RBLOCK to Start.") (princ) Quote GP_ Rising Star GP_ Community Members 14 311 posts AutoCAD 2017 Posted May 20, 2013 My version, also for Dynamic&Anonymous blocks. :) ;;; file: RB_en.lsp ;;; ;;; data: 22/10/2008 ;;; ;;; note: Rename the selected block. ;;; ;;; ;;; ;;; aggiornamento: (Versione 2) - 01/04/2009 ;;; ;;; - default sulla casella OK ;;; ;;; - controllo esistenza nome blocco ;;; ;;; ;;; ;;; aggiornamento: (Versione 3) - 02/04/2009 ;;; ;;; - allargata casella editazione nome blocco ;;; ;;; ;;; ;;; aggiornamento: (Versione 4) - 28/10/2012 ;;; ;;; - rinomina blocchi dinamici e blocchi anonimi ;;; ;;; - creazione di blocchi anonimi ;;; ;;; - inglobamento DCL nel lisp ;;; ;;; ;;; ;;; aggiornamento: (V. 4_en) - 20/05/2013 ;;; ;;; - English Version (for CADTutor) ;;; ;;; ;;; ;;; autore: Gian Paolo Cattaneo ;;; (defun c:RB (/ :bb old new dcl_id)
Solved! Go to Solution.