Typemismatch when duplicating graph
Long time ago I have created a VBA code in which I create several
graphs from data in worksheets. It was developed and is still working
in Excel 2003.
Now with Excel 2007 and Excel 2010 Beta I get
Run-time error '13':
Type mismatch
when program control reaches the line:
Set graf = list.ChartObjects(1).Duplicate
The variables are explicitly declared with:
Dim list As Worksheet, graf As ChartObject
Any ideas how to solve the problem?
TIA, Primoz
|