Home |
Search |
Today's Posts |
#1
![]() |
|||
|
|||
![]()
All,
I am creating a chart which is based on multiple columns worth of data. The problem is that the amount of rows changes and I have to be able to handle that programmaticaly. In other words, if the amount of rows was constant somewhere in my sub I would have something like: ..Chart.SetSourceData Source:=Sheets("NameGoesHere").Range("A2:A5, F2:H5") 'where the Range A2:A5 contains names that goes to label the X-axis. 'And F2:H5 represents the data for each name in A2:A5. No problem. However, I need that range to vary. I was hoping something like this would work: .Chart.ChartWizard Source:=Worksheets(xlSheet(I).Name).Range(xlSheet( I).Cells(2, 1):xlSheet(I).Cells(z, 1), xlSheet(I).Cells(2, 6):xlSheet(I).Cells(z, 8)) 'where z is an integer which calculated the number of rows needed. Problem. 'Didn't work As you can see I tried to mimic the form used for static data but failed miserably. Any help would be greatly appreciated. Clear as mud? Thanks in advance. -- J |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Dynamic charting problems (events) | Charts and Charting in Excel | |||
Pulling data from 1 sheet to another | Excel Worksheet Functions | |||
Charting data ranges that change | Charts and Charting in Excel | |||
Excel2K: Is it possible to use dynamic named ranges in custom data validation formula? | Excel Discussion (Misc queries) | |||
Named dynamic ranges, copied worksheets and graph source data | Charts and Charting in Excel |