Existing Excel Addin crashes in Excel 2007

D

Dave Hart

I have an existing Excel addin written several years ago,
which has worked without changes on Excel 97, 2000 & 2003.

With Excel 2007, it gets a run-time error '438':
"Object doesn't support this property or method."

I have tracked it down to this line of code:
For Each pnt In ech.ChartGroups(1).SeriesCollection(1).Points

where the data items are defined as:
Dim pnt As Excel.Point
Dim ech As Excel.Chart

and after ChartWizard has been called to create a 3DPie chart.

Any ideas why this should happen and how to fix it?

Thanks
Dave Hart
 
C

Cindy M.

Hi Dave,

Since you haven't gotten a response here, try asking in the more
specialized excel.programming newsgroup. The folks there may have
run into this during beta and know what's going on. The charting
engine was changed so extensively, you'll probably come across
quite a few things that no longer function the same...
I have an existing Excel addin written several years ago,
which has worked without changes on Excel 97, 2000 & 2003.

With Excel 2007, it gets a run-time error '438':
"Object doesn't support this property or method."

I have tracked it down to this line of code:
For Each pnt In ech.ChartGroups(1).SeriesCollection(1).Points

where the data items are defined as:
Dim pnt As Excel.Point
Dim ech As Excel.Chart

and after ChartWizard has been called to create a 3DPie chart.

Any ideas why this should happen and how to fix it?

Cindy Meister
INTER-Solutions, Switzerland
http://homepage.swissonline.ch/cindymeister (last update Jun 17
2005)
http://www.word.mvps.org

This reply is posted in the Newsgroup; please post any follow
question or reply in the newsgroup and not by e-mail :)
 
D

Dave Hart

Cindy

Thanks for the reply, I eventually solved it myself.
I got it to work by extracting a block of the code from the function
and defining it as a separate function, called by the main one.
I have no idea why that fixed it, but it now works.

Dave
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top