MrAshton
03-14-2008, 02:59 PM
How can I make the chart title = to a value in a cell or a stored value
This is the code I have: With ActiveChart
.HasTitle = True
.ChartTitle.Characters.Text = [e1]
.Axes(xlCategory, xlPrimary).HasTitle = True
.Axes(xlCategory, xlPrimary).AxisTitle.Characters.Text = "Category"
.Axes(xlValue, xlPrimary).HasTitle = True
.Axes(xlValue, xlPrimary).AxisTitle.Characters.Text = "Total"
End With As you can imagine, the ChartTitle object with characters.Text does not accept the [e1] method. I've tried other combinations like simply:
.ChartTitle.Formula = [e1] and
.ChartTitle.select
selection.formula = [e1] and
ChartTitle = [e1]
Nothing is accepted. Is there a way to make the title equal to the value in tha range E1?
This is the code I have: With ActiveChart
.HasTitle = True
.ChartTitle.Characters.Text = [e1]
.Axes(xlCategory, xlPrimary).HasTitle = True
.Axes(xlCategory, xlPrimary).AxisTitle.Characters.Text = "Category"
.Axes(xlValue, xlPrimary).HasTitle = True
.Axes(xlValue, xlPrimary).AxisTitle.Characters.Text = "Total"
End With As you can imagine, the ChartTitle object with characters.Text does not accept the [e1] method. I've tried other combinations like simply:
.ChartTitle.Formula = [e1] and
.ChartTitle.select
selection.formula = [e1] and
ChartTitle = [e1]
Nothing is accepted. Is there a way to make the title equal to the value in tha range E1?