How can I assign a random name to all charts in excel?

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?


This will work for sheet-type Charts:

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

Need Your Help

Java Swing: JTree DefaultMutableTreeNode not updating

java swing jtree children treenode

I have recently been working on a Java Swing project and today I get stuck when modifying childrens of a DefaultMutableTreeNode.

When to package-private (no explicit modifier) in java?

java class-visibility

I have been reading the tutorial Controlling Access to Members of a Class. I am confused what might be good use case for using package-private. Because as I understand, you can always change your p...