Well I put the code in the sheet and tried to run it, but I got
Compile Error: Sub or Function not defined.
ActiveSheet.Names.Add Name:=curname & "_" & arr(j - 1), RefersTo:="=offset(" & curname & ",0," & j & ")"
It highlights the part that I've bolded, arr. I'm not sure what this code is doing so I can't figure out how to fix that...
Edit: Nevermind that, I'm stupid. I fixed that "problem." But now I'm having an actual one.
Run-time error '1004':
Method "Rows" of object_Global failed.
It highlights the first line of that code in yellow for me.
Double edit so I don't just bump this thread for no reason: I figured that one out. I copied the code you wrote for me into my previous macro right after the macro created and moved a chart for me, so the chart was selected. I just added a line to select Cell A1 before it starts the loop and it was all good. Now to figure out everything else.
Bookmarks