Thread: chart settings
View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
Paul Paul is offline
external usenet poster
 
Posts: 108
Default chart settings

VBA does not like my syntax on the variables in the last
two lines. Please tell me what I am doing wrong:

Sub ONEDAY()
Dim maxrow As Integer
Dim onedayopen As Integer

maxrow = Sheets("DATA").[AA1].Value

onedayopen = maxrow - 4000


ActiveSheet.ChartObjects("Chart 1").Activate
ActiveChart.SeriesCollection(1).XValues = "=DATA!
RonedayopenC1:RmaxrowC1"
ActiveChart.SeriesCollection(1).Values = "=DATA!
RonedayopenC12:RmaxrowC12"

End Sub