Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.charting
external usenet poster
 
Posts: 39
Default SeriesCollection question

Very simple question....

Is there a way to get the max number of the SeriesCollection? The
reason I am asking is that I use a date range to properly configure
my chart Based off the dates, I may have different amount if
seriescollections.
  #2   Report Post  
Posted to microsoft.public.excel.charting
external usenet poster
 
Posts: 6,582
Default SeriesCollection question

I'm not sure what you're asking for. I hope this brackets your question, or
at least gives you a hint.

The maximum number of series in a chart: 255

The number of points in a series:
ActiveChart.SeriesCollection(i).Points.Count

The maximum Y value in a series:
WorksheetFunction.Max(ActiveChart.SeriesCollection (i).Values)

The maximum X value in a series:
WorksheetFunction.Max(ActiveChart.SeriesCollection (i).XValues)

Loop these last two to get the overall max:

For i=1 to ActiveChart.SeriesCollection.Count
If MaxY < WorksheetFunction.Max(ActiveChart.SeriesCollection (i).Values)
Then
MaxY = WorksheetFunction.Max(ActiveChart.SeriesCollection (i).Values)
Then
End If
Next

- Jon
-------
Jon Peltier, Microsoft Excel MVP
Peltier Technical Services, Inc.
http://PeltierTech.com/WordPress/
_______


"EAB1977" wrote in message
...
Very simple question....

Is there a way to get the max number of the SeriesCollection? The
reason I am asking is that I use a date range to properly configure
my chart Based off the dates, I may have different amount if
seriescollections.



  #3   Report Post  
Posted to microsoft.public.excel.charting
external usenet poster
 
Posts: 39
Default SeriesCollection question

Jon, that helped a lot! Thanks!
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
Unable to get SeriesCollection runtime error Kate Charts and Charting in Excel 3 March 7th 07 02:41 AM
.SeriesCollection(2).Name and .Deselect Peter Sie Charts and Charting in Excel 2 July 3rd 06 03:10 AM
Creating a plot in Excel with SeriesCollection CLamar Charts and Charting in Excel 2 June 12th 06 05:56 PM
Chart: range info from seriescollection? Excelerate-nl Charts and Charting in Excel 1 May 24th 06 04:37 AM
SeriesCollection Values Property Oddity Greg Wilson Charts and Charting in Excel 4 December 3rd 05 04:26 AM


All times are GMT +1. The time now is 02:29 PM.

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

About Us

"It's about Microsoft Excel"