Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Discontinuous Data Source for Chart?
For some reason my code keeps grabbing my entire block of data instead of the
last 6 rows. I have captured the cell addresses in variables and am trying to capture the new ranges of data in the syntax for the chart. Not sure where my problem resides. My data will expand by one row every week. The headings are in cell B20 and C20. The chart code is not grabbing discontinuous data but all 24 rows when I only want the heading row plus 6 rows of data. Here is my code: Set rngBurndownData = shtTotalData.Range("$A20").CurrentRegion DateAddress = Cells(Rows.Count, "A").End(xlUp).Address shtTotalData.Range(DateAddress).Select ActiveCell.Offset(0, 2).Select LastRngCell = ActiveCell.Address 'bottom right hand range cell in last column ActiveCell.Offset(-5, -2).Select AcolDateAddr = ActiveCell.Address 'first cell in range A column Charts.Add ActiveChart.ChartType = xlColumnStacked ActiveChart.SetSourceData Source:=Sheets("Total Data").Range( _ "$A$20:$C$20", AcolDateAddr & ":" & LastRngCell), PlotBy:=xlColumns ActiveChart.Location Whe=xlLocationAsNewSheet Any help is greatly appreciated! |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
how do I show a discontinuous chart axis | Charts and Charting in Excel | |||
How to make a chart with selective (discontinuous) data? | Charts and Charting in Excel | |||
pie chart & column chart w/same source data | Charts and Charting in Excel | |||
How do you link chart source data when you copy the chart? | Charts and Charting in Excel | |||
Discontinuous lines in series due to gaps in data points | Charts and Charting in Excel |