ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   2007: Chartwizard bugs (https://www.excelbanter.com/excel-programming/377851-2007-chartwizard-bugs.html)

mrt

2007: Chartwizard bugs
 
Problems with the Chartwizard:

- If you select a range with two columns and use it as the source with the
ActiveChart.ChartWizard method, for an xlXYScatter chart, you'll get two
series, while you had one previously (and that was LOGICAL).

- If you set Categorylabels:=True, SeriesLabels:=False, and if the first
category is empty, Excel 2007 decides that in fact, SeriesLabels is true. Why
that, no clue. It wasn't so before. And it was better before because it was
so before.

No, no, that's not the beta ...

MrT



mrt

2007: Chartwizard bugs
 
Just a comment on that

- If you select a range with two columns and use it as the source with the
ActiveChart.ChartWizard method, for an xlXYScatter chart, you'll get two
series, while you had one previously (and that was LOGICAL).


- If you set Categorylabels:=True, SeriesLabels:=False, and if the first
category is empty, Excel 2007 decides that in fact, SeriesLabels is true. Why
that, no clue. It wasn't so before. And it was better before because it was
so before.


In fact, that's the same problem as above. Then it forces to consider
serieslabels as true.


mrt

2007: Chartwizard bugs
 
Many things related to the chart wizard behavior have been changed. Automatic
guesses are weird and totally ineffective, and sometimes depend on the
chart/data types. CategoriesLabels and SeriesLabels are not taken into
account if guesses have been made. It will be a big hassle to adapt your code
to version 2007. Believe me.

MrT

H Adler

2007: Chartwizard bugs - Mr
 
Little late but here's how I did it...

'Set PlotRange = Union(GraphRange1, GraphRange2)
'ActiveChart.ChartWizard Source:=PlotRange, _
Gallery:=xlXYScatter, Format:=1, PlotBy:=1, CategoryLabels:=1, _
SeriesLabels:=0, HasLegend:=2, Title:=ChartTitle & _
CategoryTitle:=CatAxisTitle, ValueTitle:=ValueAxisTitle, ExtraTitle:=""

ActiveChart.SeriesCollection(1).XValues = GraphRange2
ActiveChart.SeriesCollection(1).Values = GraphRange1
ActiveChart.ChartTitle.Caption = ChartTitle

ActiveChart.ChartType = xlXYScatter
ActiveChart.HasLegend = False
ActiveChart.Axes(xlCategory).HasTitle = True
ActiveChart.Axes(xlCategory).AxisTitle.Caption = CatAxisTitle
ActiveChart.Axes(xlValue).HasTitle = True
ActiveChart.Axes(xlValue).AxisTitle.Caption = ValueAxisTitle

Cheers
/H Adler

EggHeadCafe.com - .NET Developer Portal of Choice
http://www.eggheadcafe.com


All times are GMT +1. The time now is 02:04 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com