View Single Post
 
Old 04-24-2012, 10:06 AM
RichardP RichardP is offline Windows 7 32bit Office 2010 32bit
Novice
 
Join Date: Apr 2012
Location: France 80%, UK 20%
Posts: 9
RichardP is on a distinguished road
Unhappy Problem saving in Word 2007 a dotm Addin developed in Word 2010

I hope someone can help me.

I've developed an AddIn in Word 2010 which works fine in Word 2010 on my Windows 7 (English edition) machine.

I copy it to my Dev folder on my Word 2007 machine (I should add that this latter machine is French Windows XP SP3, French Office 2007).

This AddIn is fairly complex (132 modules, including forms, code and class modules) and references Excel, Outlook and Powerpoint (VBE).

So when I open it on the Office 2007 machine (by right-clicking it in Windows Explorer then Open), I expect to get referencing errors, which I do.

I then dutifully open the VBE, remove the Excel, Outlook and Powerpoint references (14.0) which are naturally reported as missing, and add the 12.0 references from the dropdown list. Interestingly enough, the Word reference has automatically changed to 12.0! All the required references are now check-marked, including scrrun (Microsoft Scripting).

I compile and immediately get an error in French (something like "can't find object library or wrong object library"), even though all the References are apparently correct, and I've ascertained their physical presence in the reported paths. More worryingly, I can't save the AddIn, either in the VBE window or in the main Word window. I always get a very unhelpful error "An error has occurred" followed by the path.

After some research, I'm wondering whether a "reverse-engineering" registry hack is in order, after finding this on technet:

In Office 2010, Visual Basic for Applications (VBA) 6.0 was updated to VBA 7.0. VBA 7.0 settings were reset to their defaults after migration instead of automatically repopulating. This occurred because the registry settings for VBA are in a different hive in Office 2010:

Office 2010
HKEY_CURRENT_USER\SOFTWARE\Microsoft\VBA\7.0\Commo n

"HKEY_CURRENT_USER\SOFTWARE\Microsoft\VBA\6.0\Comm on" in 2000 thru 2007
"HKEY_CURRENT_USER\SOFTWARE\Microsoft\VBA\7.0\Comm on" in 2010

I don't really understand this, but should I add a '7.0' key in my 2007 machine's registry?

Or is the problem elsewhere?
Reply With Quote