Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
i record a macro which plot a chart getting its data from sheet1's columns.
it's works inwhich created Excel workbook but when i try to run in different Excel workbook which has different name, macro returns "unable to set Xvalues property of series class" eror. I think this is because of the column adressing for "chart series data". How can i create a macro which gets its data from active workbook's active sheet columns? Charts.Add ActiveChart.ChartType = xlXYScatterSmooth ActiveChart.SetSourceData Source:=ThisWorkbook.Sheets("Sheet1").Range("H100" ) ActiveChart.SeriesCollection.NewSeries ActiveChart.SeriesCollection.NewSeries 'code fail here... ActiveChart.SeriesCollection(1).XValues = "=Sheet1!C5" ActiveChart.SeriesCollection(1).Values = "=Sheet1!C4" |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Macro to change position of chart labels on line chart | Charts and Charting in Excel | |||
Chart macro | Charts and Charting in Excel | |||
About chart with a macro | Excel Programming | |||
Chart using Macro | Charts and Charting in Excel | |||
Chart Macro | Excel Programming |