VBA compatibility in 2003 vs 2010

eros

Board Regular
Joined
May 6, 2011
Messages
90
Hi everyone,

I have created a UserForm to which I embedded a Spreadsheet and a ChartSpace object in VBA 2003. When I upgraded to Office 2010, my form does not work. I get a message when I load the Excel file:
"Could not load some objects because they are not available on this machine". When I press Ok, another error message appears:
"Compile Error: Cannot find project or library". When I press help, then Excel suggests I go to References and select the missing reference etc. Howerver, Debug does not let me go to menu items. I simply cannot stop code execution and Reference menu item is dimmed in debug mode.

I came across in the internet that some controls are not supported in Office 2010. Just to make sure, I present a small excerpt from the form below, which worked just fine with Office 2003:

Code:
With myForm.Spreadsheet1
      .Range("b2").Value = 100
      ...
 
With myForm.ChartSpace1
      .DataSource = myForm.Spreadsheet1
      ...

How can I stop debug and go to References to find the missing reference?
What might be wrong? Is there a compatibility issue between 2003 and 2010?

I initially used Office 2010 64 bit version, when I see the error, I switched back to 32 bit Office 2010. But the problem still resides...

Many thanks in advance...
 

Excel Facts

Return population for a City
If you have a list of cities in A2:A100, use Data, Geography. Then =A2.Population and copy down.
The list does not contain a never version for OWC 11.0. Meanwhile I downloaded the file which was reported MISSING, installed it and now realized my ChartSpace object is visible on the form I created, but not the Spreadsheet which holds the data for the ChartSpace object. It seems it is now the only missing object. Surprisingly the guy in your reference post has an issue with Spreadsheet object. I wonder if this particular object is not compatible with and not supported in 2010...
 
Upvote 0
OK guys. I think I have done it!

To finish up the post,

First I deleted the Spreadsheet button on Toolbox -somehow it didn't have a picture on its own button. I looked up and checked the Spreadsheet object in the list which was opened when i clicked Additional Controls on Toolbox window after I clicked mouse right button.

I just inserted a blank spreadsheet object. My VBA code referes to it directly, does not "Add" a new one. So everything works just fine now.

I hope the guy also managed how to resolve the Spreadsheet issue.

One last note: my Excel file name contains now a string: "xxx.xls (Compatibility Mode), which means truely there is a compatibility issue between 2003 and 2010. I hope Microsoft guys update all the objects to suit for 2010 shortly.

Goody day everyone, thanks again guys. I owe you for your guidance...
 
Upvote 0

Forum statistics

Threads
1,215,016
Messages
6,122,700
Members
449,092
Latest member
snoom82

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top