Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations John Tel on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Change Name Reference of an Autoshape?

Status
Not open for further replies.

itsthecheese

Programmer
Jul 25, 2006
7
US
Excel w/VBA: I'm a reorganizing my graphics and would like to streamline them with the macros attached to them... I have many random numbered autoshapes and would like to re-number then ... is there a way to do this? I can't seem to find anything related to this.

Thank you in advance for your assistance :)

drive slow...steer fast
 




If you have a LIST if the names, put the new name in the adjacent column.

Then you loop thru the list and rename
Code:
for each r in [YourRange]
  SheetObjectYourShapesAreOn.Shapes(r.value).name = r.offset(0,1).value
next


Skip,

[glasses] [red][/red]
[tongue]
 
Hi Cheezy!

You can also name Autoshapes, same as you can with cells and charts... See faq707-4055 for how to do it

Chris

Beer is God's way of telling us He loves us and wants us to be happy - Benjamin Franklin

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top