LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 33
Default Excel Macro Help for Charts

I am getting an error message when trying to have a macro create a
chart. The following is my error message:

Run-Time Error '1004'
Unbale to set the xValue property of the Seris class

The following is my code:

Charts.Add
ActiveChart.ChartType = xlLineMarkers
ActiveChart.Location Whe=xlLocationAsObject, Name:="Sheet5"
ActiveChart.SetSourceData
Source:=Sheets("Sheet4").Range("A3:A23,C3:C23"), _
PlotBy:=xlColumns
ActiveChart.SeriesCollection(1).XValues = "=(Sheet4!A8,A15,A23)"
ActiveChart.SeriesCollection(1).Values = _
"=(Sheet4!C9,C16,C24)"
ActiveChart.SeriesCollection(1).Name = "=Sheet4!A2"

All of my cells is sheet4 have valid data. I am not sure what I am
doing wrong. The should be created in sheet5
 
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
Excel Macro for Charts [email protected] Excel Programming 1 January 17th 08 05:04 PM
Macro to copy Excel charts to existing Powerpoint file [email protected] Excel Programming 1 September 18th 06 08:32 PM
VBA Code, My excel macro creates the charts on top of each other osman[_5_] Excel Programming 3 July 24th 06 09:53 PM
Creating a macro to copy a number of charts from Excel to PPT Brian Excel Programming 0 December 16th 05 04:53 PM
Global macro for resizing and reformatting Excel charts Sol Apache Excel Programming 5 October 24th 05 03:31 AM


All times are GMT +1. The time now is 10:31 AM.

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"