My first post and I'm a novice user so please excuse any naivete on my part.
I'm writing (using) some code to parse out multiple sheets that will in turn chart mulitple data sets. I can't, for the life of me, get the charts to show the dynamic titles and I'm not even sure if there's a way to make it happen. Everything else works, but the titles, which I would like to use a range of 3 cells, starting with A2:C2 on each sheet. I'm working Excel 07 but can get it on '10 if need be. Here's the code - thanks for any help you may have!
'This is the graphing portion
Set rng4 = Range("A2:C2") 'the XXX plant that makes sure we're not overloading data
Set rng3 = Range("D1:O4") 'this is the range of the graph data - no labels included
t = 0
While rng4.Value <> ""
With ActiveSheet.ChartObjects.Add _
(Left:=100, Width:=375, Top:=t, Height:=225)
.Chart.SetSourceData Source:=rng3
.Chart.ChartType = xlXYScatterLines
.Chart.HasTitle = True
.Chart.ChartTitle.Characters.Text = Range("rng4")
End With
Set rng4 = rng4.Offset(4)
Set rng3 = rng3.Offset(4, 0)
t = t + 225
Wend
Bookmarks