I wrote a macro in excel, which runs fine, and I copied it into the post processing section of my report in the Excel Report Generator. The problem occurs at the point it creates the chart. I am getting a runtime error, 'script out of range', and don't know why. The part of the script it is occruing on is:

ActiveChart.SetSourceData Source:=Sheets("Sheet2").Range("A16:F19"), PlotBy _ :=xlRows

Any help is appreciated!