View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.programming
Tom Ogilvy Tom Ogilvy is offline
external usenet poster
 
Posts: 6,953
Default Macro to change chart references

It didnt' work because you didn't do what I showed you.


s = "'" & ActiveSheet.Name
ActiveSheet.ChartObjects("Chart 1").Activate
ActiveChart.ChartArea.Select
ActiveChart.SeriesCollection(1).XValues = "=" & s & "'!R20C1:R54C1"

--
Regards,
Tom Ogilvy

"Jobe" wrote:

Thanks Tom,

But it did not work. This is what I tried,

ActiveSheet.ChartObjects("Chart 1").Activate
ActiveChart.ChartArea.Select
ActiveChart.SeriesCollection(1).XValues = "=" & s & "'!R20C1:R54C1"