CAD Forum - tips, tricks, discussion and utilities for AutoCAD, Inventor, Revit and other Autodesk products [www.cadforum.cz]
CZ | EN | DE
Login or
registration
  Visitors: 3408

CAD tip CAD tip # 12837:

   
Question CAD 
 %  platform  category 
Q - question

RenameCSV - rename layers, blocks, layouts, views, linetypes using Excel tables

A - answer 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 www.cadstudio.cz/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    1570×  

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 glossary   



Featuring:
Publish interactive 3D PDF models from AutoCAD, Inventor or Revit with Share3D More info


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