Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2
Default Obtaining Series Name and X/Y Value Ranges for Charts

In a VB application I'm trying to obtain the x and y data ranges for each
member of the seriescollection on a floating chart.

In my test case I can identify all the way down to the
SeriesCollection.count and then identify each of the four series by name
(Q1,Q2,Q3,Q4). I thought I had the code for obtaining the values of the
Series but keep getting an error.

The code I can't get is:

ActiveChart.SeriesCollection(1).xvalues

and it passes the "Run-time error '13': Type Mismatch"

Any ideas would be appreciated as it seems this is the correct code.

Ed


  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 9
Default Obtaining Series Name and X/Y Value Ranges for Charts

To retrive info of a serie use .Formula properties
E.g.
With ActiveChart.SeriesCollection(serienumber)

FormulaSrs = .Formula
iNmBgn = InStr(FormulaSrs, "(") + 1
FormulaSrs = Mid(FormulaSrs, iNmBgn, Len(FormulaSrs) - iNmBgn)
DataChart = Split(FormulaSrs, ",")
SerieName=DataChart (0)
xValues=DataChart (1)
yValues=DataChart (2)
PlotOrder=DataChart (3)
end with

"Ed Hamilton" wrote in message
et...
In a VB application I'm trying to obtain the x and y data ranges for each
member of the seriescollection on a floating chart.

In my test case I can identify all the way down to the
SeriesCollection.count and then identify each of the four series by name
(Q1,Q2,Q3,Q4). I thought I had the code for obtaining the values of the
Series but keep getting an error.

The code I can't get is:

ActiveChart.SeriesCollection(1).xvalues

and it passes the "Run-time error '13': Type Mismatch"

Any ideas would be appreciated as it seems this is the correct code.

Ed




  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2
Default Obtaining Series Name and X/Y Value Ranges for Charts

Fantastic. Exactly what I was looking for. Thanks.

ed

"Carlos" wrote in message
...
To retrive info of a serie use .Formula properties
E.g.
With ActiveChart.SeriesCollection(serienumber)

FormulaSrs = .Formula
iNmBgn = InStr(FormulaSrs, "(") + 1
FormulaSrs = Mid(FormulaSrs, iNmBgn, Len(FormulaSrs) - iNmBgn)
DataChart = Split(FormulaSrs, ",")
SerieName=DataChart (0)
xValues=DataChart (1)
yValues=DataChart (2)
PlotOrder=DataChart (3)
end with

"Ed Hamilton" wrote in message
et...
In a VB application I'm trying to obtain the x and y data ranges for

each
member of the seriescollection on a floating chart.

In my test case I can identify all the way down to the
SeriesCollection.count and then identify each of the four series by name
(Q1,Q2,Q3,Q4). I thought I had the code for obtaining the values of the
Series but keep getting an error.

The code I can't get is:

ActiveChart.SeriesCollection(1).xvalues

and it passes the "Run-time error '13': Type Mismatch"

Any ideas would be appreciated as it seems this is the correct code.

Ed






Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
How to divide a data series into different ranges? Arun Charts and Charting in Excel 2 January 14th 08 06:31 AM
Multiple Ranges and Reversing a Series BoRed79 Charts and Charting in Excel 1 September 26th 07 01:52 PM
Using a series of named ranges in SUMPRODUCT JzP Excel Worksheet Functions 7 June 18th 07 05:29 PM
Charts switch from 'Series in Rows' to 'Series in Columns' Peace Charts and Charting in Excel 4 March 22nd 07 03:52 AM
Two ranges in one series Micayla Bergen Charts and Charting in Excel 1 August 11th 05 03:19 PM


All times are GMT +1. The time now is 12:56 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"