CAD Forum - tips, tricks, discussion and utilities for AutoCAD, Inventor, Revit and other Autodesk products [www.cadforum.cz] ARKANCE | CONTACT - CZ | SK | EN | DE
Over 1.096.000 registered users (EN+CZ). AutoCAD tips, Inventor tips, Revit tips. Try the new precise Engineering calculator and the updated Barcode generator. New AutoCAD 2026 commands and variables.

CAD tip CAD tip # 12837:

Question

CAD 
 %  platform  category 
A
How to rename layers or blocks in a DWG drawing in Excel?

The RenameCSV LISP utility by CAD Studio allows to mass rename AutoCAD symbol tables like layers, blocks, views, styles, etc. using Excel or other worksheet table or database apps (CSV files).

Download RenameCSV from DL Download, load it into your AutoCAD with APPLOAD and start the RENAMECSV command.

Rename [Blocks/Layers/lineTypes/layOuts/Views/Textstyles/Dimstyles/Materials/viewPorts/Ucs/Groups] < ALL>:

Choose the style to export (or ALL) and confirm the output file name (the default is [DrawingName].REN.csv). The utility exports a CSV file of a similar type (you can set "," or ";" as a field delimiter):

OLD;NEW
;RenameCSV table exported from Drawing1.dwg
*LAYOUTS
"Layout1";"Layout1"
"Layout2";"Layout2"
*LAYERS
"Layer1";"Layer1"
"MyLayer2";"MyLayer2"
*BLOCKS
*LINETYPES
"ByBlock";"ByBlock"
"Continuous";"Continuous"
*VIEWS
*TEXTSTYLES
"Annotation";"Annotation"
*DIMSTYLES
"Annotation";"Annotation"
"ISO-25";"ISO-25"
*MATERIALS
*VIEWPORTS
*UCS
*GROUPS

Open this file in your Excel and edit any names in the second column ("NEW") you want to change (rename). Save the CSV file.

Now start (type) the RenameImp command in AutoCAD, select the same CSV file and let it perform all the imported rename operations (from OLD to NEW).

If you are renaming symbols in similar DWG drawings (containing same named blocks, layers, layouts, etc.), you can start just with the command RenameImp and re-use a single common renaming table (a "translation" vocabulary for name replacements). If you disable FILEDIA, you can run commands in this application also from batch scripts, e.g. through ScriptPro.

See also the RRename utility for symbol table renaming using regular expressions.

ACADPlantMapCivilMech
100% *CAD
6.1.2021    63516×  

See also:
Tip 6920:How to add a suffix or prefix to all layers.


Back    All CAD Tips



Have we helped you? If you want to support the CAD Forum web service, consider buying one of our CAD applications, or our custom software development offerings, or donating via PayPal (see above). You may also add a link to your web - like this "fan" link: CAD Forum - tips, utilities, blocks for Autodesk products
CAD: 
OS: 
Categ: 
Text:
 FAQ
  



Featuring:
DwgTextTranslator translates a series of drawings from one language to another using MS Access.
Download a fully functional trial version.


Please use these tips at your own risk.
ARKANCE is not responsible for possible problems that may occur as a result of using any of these tips.
TOPlist