Anuncios

The Autodesk Community Forums has a new look. Read more about what's changed on the Community Announcements board.

Anonymous
6182 Vistas, 20 Respuestas

Wildcard Character * Not Allowing Renaming of Multiple Layers

In the RENAME dialog, I am using the *wildcard character to rename multiple layers.
See Attached.
But No Layers are renamed.
What's the problem?

Thanks

dbroad
en respuesta a: Anonymous

I don't believe the rename command supports bulk renaming with wildcards.  You would need to write a program for that I think.

Architect, Registered NC, VA, SC, & GA.
kadmonkee
en respuesta a: Anonymous

try changing the syntax

*Anno* doesn't match the actual name

you may need to include the tilde symbol






If there is any information shared that is of value please give Kudos
If a solution is provided by any posters please mark them as Solved to benefit everyone else.
thank you
vladimir_michl
en respuesta a: dbroad

You can use RRENAME for complex renaming of AutoCAD layers and other named objects. It supports also regular expresssions.

 

See http://www.cadforum.cz/cadforum_en/rename-on-steroids-complex-renaming-of-autocad-objects-tip9265

 

Vladimir Michl, www.cadstudio.cz  www.cadforum.cz

 

Anonymous
en respuesta a: Anonymous

Works fine here, I believe your issue result from using a wildcard character in the layer name itself.  The tilde (~) is a wildcard character and using it in layer names is probably affecting the rename capabilities.

 

rename1.PNGrename2.PNG

dbroad
en respuesta a: Anonymous

Looks like it will work for changing prefixes, but I can't make it change an internal substring.  Can you?

 

1-Layer1

2-Layer2

3-Layer3

4-Layer4

etc.

 

rename old name:*Layer*,  New name: *L*

 

won't work.

Architect, Registered NC, VA, SC, & GA.
vladimir_michl
en respuesta a: dbroad

With RRENAME you can rename (just by entering "Layer" --> "L"):

 

1-Layer1 --> 1-L1

2-Layer2 --> 2-L2

3-Layer3 --> 3-L3

 

But you can even rename e.g.:

 

1-LayerA --> A-L1

2-LayerB --> B-L2

3-LayerC --> C-L3

 

by entering "(.+)-Layer(.+)" --> "$2-L$1"

 

Vladimir Michl, www.cadstudio.cz  www.cadforum.cz

 

 

serkancavuslar
en respuesta a: Anonymous

Hi @Anonymous

 

Command "lrn"

LayerName Rename

 

Replace

 

Turkey / Istanbul

 

LayerRename.png

Serkan ÇAVUŞLAR
CplCAD / Türkiye
Etiquetas (1)
kadmonkee
en respuesta a: Anonymous

here is a list of Acceptable wildcards for Autocad

 

Character
Definition

# (Pound)
Matches any numeric digit

@ (At)
Matches any alphabetic character

. (Period)
Matches any nonalphanumeric character

* (Asterisk)
Matches any string and can be used anywhere in the search string

? (Question mark)
Matches any single character; for example, ?BC matches ABC, 3BC, and so
on

~ (Tilde)
Matches anything but the pattern; for example; ~*AB*matches all strings
that don't contain AB

[ ]
Matches any one of the characters enclosed; for example, [AB]C matches
AC and BC

[~]
Matches any character not enclosed; for example, [~AB]C matches XC but
not AC

[-]
Specifies a range for a single character; for example, [A-G]C matches
AC, BC, and so on to GC, but not HC

` (Reverse quote)
Reads the next character literally; for example, `~AB matches ~AB






If there is any information shared that is of value please give Kudos
If a solution is provided by any posters please mark them as Solved to benefit everyone else.
thank you
Anonymous
en respuesta a: kadmonkee

In addition to @kadmonkee 's list it is important to remember NOT to use any of those characters in layer names (or any other name for that matter).

Anonymous
en respuesta a: dbroad
serkancavuslar
en respuesta a: Anonymous

Some solutions can be very simple and practical.

This method is very easy and very practical as you can see.

 

 

Serkan ÇAVUŞLAR
CplCAD / Türkiye
Etiquetas (1)
Anonymous
en respuesta a: serkancavuslar

Thanks for the .lsp file for advanced renaming functionality, since the standard RENAME dialog apparently does not permit multiple * characters.

It successfully solved my particular layer renaming task. It even successfully dealt with the tilde character I had as part of my layer name, which I removed as part of the layer name, since it is a wildcard character itself (kadmonkee's list & rculp's advice, thanks)

Anonymous
en respuesta a: Anonymous

RENAME works quite well using wildcards, your problem was the wildcard character you used in the layer name. Don't do that and RENAME works fine.

Anonymous
en respuesta a: serkancavuslar

Do you have a similar lisp file for renaming blocks?

ntodd
en respuesta a: Anonymous

Someone has used '_' underscore instead of '-' hyphen in multiple layers. I want to change those layers to use a hyphen. The wildcards didn't work. Any thoughts?

Thanks!

RobDraw
en respuesta a: ntodd


@ntodd wrote:

The wildcards didn't work.


 

Which wildcard did you use and how did you apply it?


Rob

Drafting is a breeze and Revit doesn't always work the way you think it should.
Anonymous
en respuesta a: Anonymous

I'm not sure why people are ignoring this, but this RRename, rocks! Thank you.

RobDraw
en respuesta a: Anonymous

What makes you think it is being ignored?


Rob

Drafting is a breeze and Revit doesn't always work the way you think it should.
Anonymous
en respuesta a: serkancavuslar

Hello,

 

this seems not to work for AutoCAD Archtitecture 2019. It just says unnown command "LayerName"

 

Any solution for this?