A
adminis
Unregistered / Unconfirmed
GUEST, unregistred user!
我用下面的语句后绘制出了Series和Categories,但是数据区是空的没有绘制出来,请问还缺什么步骤?如何使数据区也绘制出来?
var
WCChart1: WCChart;
begin
with ChartSpace1do
begin
Clear;
Refresh;
DataSource := PivotTable1.DefaultInterface as MSDATASRC_TLB.DataSource;
WCChart1 := Charts.Add(0);
with WCChart1do
begin
Type_ := chChartTypeColumnClustered;
SetData(chDimSeriesNames, 0, chPivotColumns);
SetData(chDimCategories, 0, chPivotRows);
end;
end;
end;
var
WCChart1: WCChart;
begin
with ChartSpace1do
begin
Clear;
Refresh;
DataSource := PivotTable1.DefaultInterface as MSDATASRC_TLB.DataSource;
WCChart1 := Charts.Add(0);
with WCChart1do
begin
Type_ := chChartTypeColumnClustered;
SetData(chDimSeriesNames, 0, chPivotColumns);
SetData(chDimCategories, 0, chPivotRows);
end;
end;
end;