Where is the data in my series collection?

M

M Spiff

Hi all,

I'm working with and OWC chart ("ochart") that has series collections
made from an excel spreadsheet object.

I thought that I should be able to look at the
"ochart.SeriesCollection(n).[something]" to review the actuall data
points.

In searching the object, I have not been able to locate the actual
data values, nor a reference to spreadsheet1 where the data actually
lives.

Could you point me in the right direction to query a series collection
for its data values?

Thanks so much,

MP
 
T

Thao Moua [ms]

Use this code to extract the actual value:

webchart.charts(0).seriescollection(0).points(x).getvalue(chDimValues)

----------------------------------------------------------------------
Thao Moua
OWC Chartspace Support

This posting is provided "AS IS" with no warranties, and
confers no rights. Use of included script samples are
subject to the terms specified at
http://www.microsoft.com/info/cpyright.htm
 
K

Katie

Is there a better way to find out the details of a series collection?

Can you set a name for a series?

I'm working with Excel in .NET (using PIA), and I'm trying to set one of the
series to the Y axis but the problem is I can't tell which series in the
collection it is. I add the series to the collection at the end and that's
the one that I'm trying to set on the Y axis

oXLChart = oXLSheet.Parent.Charts.Add
oXLChart.ChartType = Excel.XlChartType.xlXYScatterSmooth
oXLChart.SetSourceData(oXLRange,
oXLChartClass.PlotBy.xlColumns)

oXLChart.Location(Excel.XlChartLocation.xlLocationAsNewSheet, "TEST2")

With oXLChart
.HasTitle = True
.ChartTitle.Characters.Text = "Average Performance"
.Axes(Excel.XlAxisGroup.xlPrimary)
.Axes(Excel.XlAxisType.xlCategory,
Excel.XlAxisGroup.xlPrimary).HasTitle = True
.Axes(Excel.XlAxisType.xlCategory,
Excel.XlAxisGroup.xlPrimary).AxisTitle.Characters.Text = "Elapsed Time
(minutes)"
.Axes(Excel.XlAxisType.xlValue,
Excel.XlAxisGroup.xlPrimary).HasTitle = True
.Axes(Excel.XlAxisType.xlValue,
Excel.XlAxisGroup.xlPrimary).AxisTitle.Characters.Text = "Pages Rcvd/sec"
End With

'THIS IS THE RANGE I WANT on the Y axis
oXLChart.SeriesCollection.Add(oXLYRange)
oXLSeriesCollect = CType(oXLChart.SeriesCollection(),
Excel.SeriesCollection)

How would you set it? .NET is a bit tricky because you have the APIs aren't
documented very well and you have to extrapolate from the VB Excel user docs.

I'd really appreciate any guidance since I am extremely new to Excel and
Chart objects.

Thanks!


Thao Moua said:
Use this code to extract the actual value:

webchart.charts(0).seriescollection(0).points(x).getvalue(chDimValues)

----------------------------------------------------------------------
Thao Moua
OWC Chartspace Support

This posting is provided "AS IS" with no warranties, and
confers no rights. Use of included script samples are
subject to the terms specified at
http://www.microsoft.com/info/cpyright.htm
----------------------------------------------------------------------

M Spiff said:
Hi all,

I'm working with and OWC chart ("ochart") that has series collections
made from an excel spreadsheet object.

I thought that I should be able to look at the
"ochart.SeriesCollection(n).[something]" to review the actuall data
points.

In searching the object, I have not been able to locate the actual
data values, nor a reference to spreadsheet1 where the data actually
lives.

Could you point me in the right direction to query a series collection
for its data values?

Thanks so much,

MP
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top