1
votes

I have a lot of charts in excel which look similar but with different data ranges, however they also have the same chart names. This becomes a problem when I am linking these charts to Powerpoint!

Is there a way to assign a random name to all charts in my workbook?

1
What do you mean by random? e.g. Chart1, Chart2, Chart3... etc.Alex P
Yes, or anything similar as long as each chart has a different name.ab_s

1 Answers

2
votes

This will work for sheet-type Charts:

Sub dural()
    For Each Chart In ActiveWorkbook.Charts
        Chart.Name = "Chart" & CStr(Rnd())
    Next
End Sub