bustr Posted March 27, 2012 Posted March 27, 2012 Is there any way to rename a tag without using battman? I need to replace some drawing borders and some of the attribute tags on the new border are named differently from the tags on the old border. I'd like to be able to use transparent commands to make a script file to do it automatically instead of calling up battman, clicking through and typing on every single one. Quote
pmxcad Posted March 27, 2012 Posted March 27, 2012 http://forums.augi.com/showthread.php?t=100153 Quote
bustr Posted March 28, 2012 Author Posted March 28, 2012 Thanks! I used one of them form the page and it worked. Quote
irneb Posted April 1, 2012 Posted April 1, 2012 (edited) Hi, I'm not sure if you've used my old code over at AUGI. If so here's an update. I can't check since AUGI is down at the moment. The file contains 2 commands: RenAttrSet - this opens a dialog listing all the blocks containing attributes in the current drawing. You can then add these blocks to the renaming settings. Note it even incorporated block references which have attributes not found in the definition (i.e. those attributes which would disappear with AttSync / BAttMan). After you've added the blocks you wish to "fix" select the relevant block / attrib in the right (note duplicate names are listed as well). Then enter the new name below and click "Save". If you start this command again, your previous settings should already be listed, adding other blocks simply adds to these - so you can build up multiple renaming settings globally accross various files. After you've finished, click OK and these settings are saved into a file for future reference. RenAttr - this reads the settings from the file created above. It steps though the entire drawing (including nested blocks and block definitions) renaming attributes as setup in the above command. So it basically gives a less geeky method of creating the rename list, and then a simple command to perform the rename globally. Easier to run in a script, as after you've setup the renaming settings once, you have the script load the LSP file and run RenAttr. HTH RenAttrib.LSP Edited April 1, 2012 by irneb Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.