S
Sridhar
Hi,
Iam trying to bind the OWC10 chart component with OWC10 spreadsheet
component as datasource in VB.net. Iam not getting any errors. But in the
output iam not getting any graph. It shows an empty graph.
This is my programming environment.
OS : Windows 2000 SP3
MS-Office : Office XP - 2002 - SP1
Tool : Visual Studio 2003
Framework : .NET Framework 1.1
Web Component : Microsoft Web Components 10.0
This is the code i used,
Imports AxOWC10
Dim oChart
Dim oSeries1, oSeries2
Dim oAxis1, oAxis2
With AxChartSpace1
.Clear()
.Refresh()
.DataSource = AxSpreadsheet1.GetOcx
End With
'Create a new chart in the ChartSpace.
oChart = AxChartSpace1.Charts.Add
'Add a series of type Column.
oSeries1 = oChart.SeriesCollection.Add
oSeries1.Caption = "LSFO SOB"
oSeries1.SetData(OWC10.ChartDimensionsEnum.chDimCategories,
OWC10.ChartSpecialDataSourcesEnum.chDataLiteral,
AxSpreadsheet1.ActiveSheet.Range(AxSpreadsheet1.ActiveSheet.Cells(2, 1),
AxSpreadsheet1.ActiveSheet.Cells(26, 1)).Address) '"A2:A26"
oSeries1.SetData(OWC10.ChartDimensionsEnum.chDimValues,
OWC10.ChartSpecialDataSourcesEnum.chDataLiteral,
AxSpreadsheet1.ActiveSheet.Range(AxSpreadsheet1.ActiveSheet.Cells(2, 2),
AxSpreadsheet1.ActiveSheet.Cells(26, 2)).Address) ' "B2:B26"
oSeries1.Type = OWC10.ChartChartTypeEnum.chChartTypeColumnStacked
Could any of you please help me, what is the problem ?
I checked all the sites, everywhere the syntax for setdata is the same what
i gave. Even then iam not getting the graph. Please help me to sort out the
issue.
Iam trying to bind the OWC10 chart component with OWC10 spreadsheet
component as datasource in VB.net. Iam not getting any errors. But in the
output iam not getting any graph. It shows an empty graph.
This is my programming environment.
OS : Windows 2000 SP3
MS-Office : Office XP - 2002 - SP1
Tool : Visual Studio 2003
Framework : .NET Framework 1.1
Web Component : Microsoft Web Components 10.0
This is the code i used,
Imports AxOWC10
Dim oChart
Dim oSeries1, oSeries2
Dim oAxis1, oAxis2
With AxChartSpace1
.Clear()
.Refresh()
.DataSource = AxSpreadsheet1.GetOcx
End With
'Create a new chart in the ChartSpace.
oChart = AxChartSpace1.Charts.Add
'Add a series of type Column.
oSeries1 = oChart.SeriesCollection.Add
oSeries1.Caption = "LSFO SOB"
oSeries1.SetData(OWC10.ChartDimensionsEnum.chDimCategories,
OWC10.ChartSpecialDataSourcesEnum.chDataLiteral,
AxSpreadsheet1.ActiveSheet.Range(AxSpreadsheet1.ActiveSheet.Cells(2, 1),
AxSpreadsheet1.ActiveSheet.Cells(26, 1)).Address) '"A2:A26"
oSeries1.SetData(OWC10.ChartDimensionsEnum.chDimValues,
OWC10.ChartSpecialDataSourcesEnum.chDataLiteral,
AxSpreadsheet1.ActiveSheet.Range(AxSpreadsheet1.ActiveSheet.Cells(2, 2),
AxSpreadsheet1.ActiveSheet.Cells(26, 2)).Address) ' "B2:B26"
oSeries1.Type = OWC10.ChartChartTypeEnum.chChartTypeColumnStacked
Could any of you please help me, what is the problem ?
I checked all the sites, everywhere the syntax for setdata is the same what
i gave. Even then iam not getting the graph. Please help me to sort out the
issue.