469,270 Members | 1,510 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,270 developers. It's quick & easy.

runtime error during the loading of the COM add-in

I have no idea what is going on...
I took an add-in for Office 2007 that I started in VS 2003, and imported
the whole thing into VS 2005. Then I added some custom .Net components
from Developer Express (devexpress.com) to the project.
I have a rather long list of references now: Accessibility, a bunch of
DevExpress components, Extensibility, Microsoft.Office.Core,
Microsoft.Interop.* (all ribbon app ones), stdole, System,
System.Drawing, System.Windows.Forms, System.XML. The setup program is
the one generated by VS 2005.
The add-in works fine on my development machine. But the moment I
install it on a different machine, it fails with a runtime error during
the loading of the COM add-in (that's what the com add-ins dialog says).
I tried it in Excel, PPT and Word. I tried displaying a message box in
the Connect and OnConnection events, but they didn't appear. So I am
thinking it crashes before it even gets into those methods, but I have
no idea what the heck it could be.
Any suggestions?

Thanks,

Patrick Schmid

Oct 25 '06 #1
10 1880

As I am encoutering pb in some similar areas, have you tried to have a
fusion log viewer look of it ?
btw, have you an idea of what makes a Excel initiate the framework 2.0
or 1.1 ?

my current pb :
http://groups-beta.google.com/group/...a3185aeaafc96b
On Oct 25, 12:37 pm, "Patrick Schmid [MVP]" <pdsch...@nospam.mvps.org>
wrote:
I have no idea what is going on...
I took an add-in for Office 2007 that I started in VS 2003, and imported
the whole thing into VS 2005. Then I added some custom .Net components
from Developer Express (devexpress.com) to the project.
I have a rather long list of references now: Accessibility, a bunch of
DevExpress components, Extensibility, Microsoft.Office.Core,
Microsoft.Interop.* (all ribbon app ones), stdole, System,
System.Drawing, System.Windows.Forms, System.XML. The setup program is
the one generated by VS 2005.
The add-in works fine on my development machine. But the moment I
install it on a different machine, it fails with a runtime error during
the loading of the COM add-in (that's what the com add-ins dialog says).
I tried it in Excel, PPT and Word. I tried displaying a message box in
the Connect and OnConnection events, but they didn't appear. So I am
thinking it crashes before it even gets into those methods, but I have
no idea what the heck it could be.
Any suggestions?

Thanks,

Patrick Schmid
Oct 25 '06 #2
Patrick,

If I understand You correctly the 2003 version of it worked as expected and
without any dev components.

At first I would simple remove the components and see if the 2005 version
add-in work in the same way as the 2003 do.

Second, I would make a clean installation of it on the developing machine to
see if it work properly. After all, running it from the IDE may not always
uncover the issues.

I find it more difficult to track down issues with the .NET then with the
classic COM so based on my own experience I've compiled an article about
troubleshooting. It's not complete and it will never be possible...
http://www.excelkb.com/article.aspx?id=10206

In my experience 'shimmed' COM Add-ins appear to have less issues then
'unshimmed' but it's not necessary the case here as it looks like it related
to the components in use.

---------------
With kind regards,
Dennis
Weekly Blog .NET & Excel: http://xldennis.wordpress.com/
My English site: http://www.excelkb.com/default.aspx
My Swedish site: http://www.xldennis.com/
Oct 25 '06 #3
Dennis,
If I understand You correctly the 2003 version of it worked as expected and
without any dev components.
Yes.
At first I would simple remove the components and see if the 2005 version
add-in work in the same way as the 2003 do.
There is a week of development between the two versions by now. I
changed every form to be completely based on those components, so simply
going back is not an option anymore at this point. I hope I can avoid
having to go through the code and commenting out everything related to
the components so that I can compile it without them...
Second, I would make a clean installation of it on the developing machine to
see if it work properly. After all, running it from the IDE may not always
uncover the issues.
It works fine on the developing machine, even if not rum from the IDE.
That's what is puzzling me really about this.
I find it more difficult to track down issues with the .NET then with the
classic COM so based on my own experience I've compiled an article about
troubleshooting. It's not complete and it will never be possible...
http://www.excelkb.com/article.aspx?id=10206
Thanks. I'm going through it.
In my experience 'shimmed' COM Add-ins appear to have less issues then
'unshimmed' but it's not necessary the case here as it looks like it related
to the components in use.
A COM shim for this add-in is on my to do list, but I doubt it makes any
sense to shim an add-in that is crashing on startup. So the shim has to
wait till I figure out what is going on here.

Thanks for your help!!

Patrick Schmid

>
---------------
With kind regards,
Dennis
Weekly Blog .NET & Excel: http://xldennis.wordpress.com/
My English site: http://www.excelkb.com/default.aspx
My Swedish site: http://www.xldennis.com/
Oct 25 '06 #4
Patrick,

Do You by any chance use classic ADO to populate the component(s)? If so You
may check out the version in use on the test machine compared with Your own
developing machine.

---------------
With kind regards,
Dennis
Weekly Blog .NET & Excel: http://xldennis.wordpress.com/
My English site: http://www.excelkb.com/default.aspx
My Swedish site: http://www.xldennis.com/
Oct 25 '06 #5
No ADO at all. I think I won't get around stripping it to the bare
minimum *sigh*

Patrick Schmid

"XL-Dennis" <XL******@discussions.microsoft.comwrote in message
news:42**********************************@microsof t.com:
Patrick,

Do You by any chance use classic ADO to populate the component(s)? If so You
may check out the version in use on the test machine compared with Your own
developing machine.

---------------
With kind regards,
Dennis
Weekly Blog .NET & Excel: http://xldennis.wordpress.com/
My English site: http://www.excelkb.com/default.aspx
My Swedish site: http://www.xldennis.com/
Oct 25 '06 #6
I have no idea what was wrong. I rebuilt the VS 2005 project from
scratch, and now it is working just fine.

Patrick

"Patrick Schmid [MVP]" <pd******@nospam.mvps.orgwrote in message
news:#z**************@TK2MSFTNGP03.phx.gbl:
No ADO at all. I think I won't get around stripping it to the bare
minimum *sigh*

Patrick Schmid

"XL-Dennis" <XL******@discussions.microsoft.comwrote in message
news:42**********************************@microsof t.com:
Patrick,

Do You by any chance use classic ADO to populate the component(s)? If so You
may check out the version in use on the test machine compared with Your own
developing machine.

---------------
With kind regards,
Dennis
Weekly Blog .NET & Excel: http://xldennis.wordpress.com/
My English site: http://www.excelkb.com/default.aspx
My Swedish site: http://www.xldennis.com/
Oct 26 '06 #7
Patrick,

I've experienced the same result and I suspect that there are some conflicts
'under the hood' when porting a VS2003 solution to VS2005.

If You have the time and interest You can use ILDASM to view the contents of
the assemblies and compare them.

On my 'wish' list I would like to have a tool that document the installation
processes and test results to reduce the time for re-creating the solution.

---------------
With kind regards,
Dennis
Weekly Blog .NET & Excel: http://xldennis.wordpress.com/
My English site: http://www.excelkb.com/default.aspx
My Swedish site: http://www.xldennis.com/
"Patrick Schmid [MVP]" wrote:
I have no idea what was wrong. I rebuilt the VS 2005 project from
scratch, and now it is working just fine.

Patrick

"Patrick Schmid [MVP]" <pd******@nospam.mvps.orgwrote in message
news:#z**************@TK2MSFTNGP03.phx.gbl:
No ADO at all. I think I won't get around stripping it to the bare
minimum *sigh*

Patrick Schmid

"XL-Dennis" <XL******@discussions.microsoft.comwrote in message
news:42**********************************@microsof t.com:
Patrick,
>
Do You by any chance use classic ADO to populate the component(s)? If so You
may check out the version in use on the test machine compared with Your own
developing machine.
>
---------------
With kind regards,
Dennis
Weekly Blog .NET & Excel: http://xldennis.wordpress.com/
My English site: http://www.excelkb.com/default.aspx
My Swedish site: http://www.xldennis.com/

Oct 26 '06 #8
Hi Dennis,

Thanks for your help! I am just glad that I got it working. Now, if it
would just work in Vista...

Patrick Schmid [OneNote MVP]
--------------
http://pschmid.net
***
Office 2007 Beta 2 Technical Refresh (B2TR):
http://pschmid.net/blog/2006/09/18/43
***
Customize Office 2007: http://pschmid.net/office2007/customize
OneNote 2007: http://pschmid.net/office2007/onenote
***
Subscribe to my Office 2007 blog: http://pschmid.net/blog/feed

"XL-Dennis" <XL******@discussions.microsoft.comwrote in message
news:16**********************************@microsof t.com:
Patrick,

I've experienced the same result and I suspect that there are some conflicts
'under the hood' when porting a VS2003 solution to VS2005.

If You have the time and interest You can use ILDASM to view the contents of
the assemblies and compare them.

On my 'wish' list I would like to have a tool that document the installation
processes and test results to reduce the time for re-creating the solution.

---------------
With kind regards,
Dennis
Weekly Blog .NET & Excel: http://xldennis.wordpress.com/
My English site: http://www.excelkb.com/default.aspx
My Swedish site: http://www.xldennis.com/
"Patrick Schmid [MVP]" wrote:
I have no idea what was wrong. I rebuilt the VS 2005 project from
scratch, and now it is working just fine.

Patrick

"Patrick Schmid [MVP]" <pd******@nospam.mvps.orgwrote in message
news:#z**************@TK2MSFTNGP03.phx.gbl:
No ADO at all. I think I won't get around stripping it to the bare
minimum *sigh*
>
Patrick Schmid
>
"XL-Dennis" <XL******@discussions.microsoft.comwrote in message
news:42**********************************@microsof t.com:
>
Patrick,

Do You by any chance use classic ADO to populate the component(s)? If so You
may check out the version in use on the test machine compared with Your own
developing machine.

---------------
With kind regards,
Dennis
Weekly Blog .NET & Excel: http://xldennis.wordpress.com/
My English site: http://www.excelkb.com/default.aspx
My Swedish site: http://www.xldennis.com/
Oct 26 '06 #9
Patrick,

The only contribution I can give on the subject is to use the beta of .NET 3.0
http://msdn.microsoft.com/library/de...ml/netfx30.asp

---------------
With kind regards,
Dennis
Weekly Blog .NET & Excel: http://xldennis.wordpress.com/
My English site: http://www.excelkb.com/default.aspx
My Swedish site: http://www.xldennis.com/
"Patrick Schmid [MVP]" wrote:
Hi Dennis,

Thanks for your help! I am just glad that I got it working. Now, if it
would just work in Vista...

Patrick Schmid [OneNote MVP]
--------------
http://pschmid.net
***
Office 2007 Beta 2 Technical Refresh (B2TR):
http://pschmid.net/blog/2006/09/18/43
***
Customize Office 2007: http://pschmid.net/office2007/customize
OneNote 2007: http://pschmid.net/office2007/onenote
***
Subscribe to my Office 2007 blog: http://pschmid.net/blog/feed

"XL-Dennis" <XL******@discussions.microsoft.comwrote in message
news:16**********************************@microsof t.com:
Patrick,

I've experienced the same result and I suspect that there are some conflicts
'under the hood' when porting a VS2003 solution to VS2005.

If You have the time and interest You can use ILDASM to view the contents of
the assemblies and compare them.

On my 'wish' list I would like to have a tool that document the installation
processes and test results to reduce the time for re-creating the solution.

---------------
With kind regards,
Dennis
Weekly Blog .NET & Excel: http://xldennis.wordpress.com/
My English site: http://www.excelkb.com/default.aspx
My Swedish site: http://www.xldennis.com/
"Patrick Schmid [MVP]" wrote:
I have no idea what was wrong. I rebuilt the VS 2005 project from
scratch, and now it is working just fine.
>
Patrick
>
"Patrick Schmid [MVP]" <pd******@nospam.mvps.orgwrote in message
news:#z**************@TK2MSFTNGP03.phx.gbl:
>
No ADO at all. I think I won't get around stripping it to the bare
minimum *sigh*

Patrick Schmid

"XL-Dennis" <XL******@discussions.microsoft.comwrote in message
news:42**********************************@microsof t.com:

Patrick,
>
Do You by any chance use classic ADO to populate the component(s)? If so You
may check out the version in use on the test machine compared with Your own
developing machine.
>
---------------
With kind regards,
Dennis
Weekly Blog .NET & Excel: http://xldennis.wordpress.com/
My English site: http://www.excelkb.com/default.aspx
My Swedish site: http://www.xldennis.com/
>
>

Oct 26 '06 #10
Thanks,

I don't see though how that would affect the code VS 2005 generates. It
will still only do .NET 2 code.

Patrick Schmid [OneNote MVP]
--------------
http://pschmid.net
***
Office 2007 Beta 2 Technical Refresh (B2TR):
http://pschmid.net/blog/2006/09/18/43
***
Customize Office 2007: http://pschmid.net/office2007/customize
OneNote 2007: http://pschmid.net/office2007/onenote
***
Subscribe to my Office 2007 blog: http://pschmid.net/blog/feed

"XL-Dennis" <XL******@discussions.microsoft.comwrote in message
news:E4**********************************@microsof t.com:
Patrick,

The only contribution I can give on the subject is to use the beta of .NET 3.0
http://msdn.microsoft.com/library/de...ml/netfx30.asp

---------------
With kind regards,
Dennis
Weekly Blog .NET & Excel: http://xldennis.wordpress.com/
My English site: http://www.excelkb.com/default.aspx
My Swedish site: http://www.xldennis.com/
"Patrick Schmid [MVP]" wrote:
Hi Dennis,

Thanks for your help! I am just glad that I got it working. Now, if it
would just work in Vista...

Patrick Schmid [OneNote MVP]
--------------
http://pschmid.net
***
Office 2007 Beta 2 Technical Refresh (B2TR):
http://pschmid.net/blog/2006/09/18/43
***
Customize Office 2007: http://pschmid.net/office2007/customize
OneNote 2007: http://pschmid.net/office2007/onenote
***
Subscribe to my Office 2007 blog: http://pschmid.net/blog/feed

"XL-Dennis" <XL******@discussions.microsoft.comwrote in message
news:16**********************************@microsof t.com:
Patrick,
>
I've experienced the same result and I suspect that there are some conflicts
'under the hood' when porting a VS2003 solution to VS2005.
>
If You have the time and interest You can use ILDASM to view the contents of
the assemblies and compare them.
>
On my 'wish' list I would like to have a tool that document the installation
processes and test results to reduce the time for re-creating the solution.
>
---------------
With kind regards,
Dennis
Weekly Blog .NET & Excel: http://xldennis.wordpress.com/
My English site: http://www.excelkb.com/default.aspx
My Swedish site: http://www.xldennis.com/
>
>
"Patrick Schmid [MVP]" wrote:
>
I have no idea what was wrong. I rebuilt the VS 2005 project from
scratch, and now it is working just fine.

Patrick

"Patrick Schmid [MVP]" <pd******@nospam.mvps.orgwrote in message
news:#z**************@TK2MSFTNGP03.phx.gbl:

No ADO at all. I think I won't get around stripping it to the bare
minimum *sigh*
>
Patrick Schmid
>
"XL-Dennis" <XL******@discussions.microsoft.comwrote in message
news:42**********************************@microsof t.com:
>
Patrick,

Do You by any chance use classic ADO to populate the component(s)? If so You
may check out the version in use on the test machine compared with Your own
developing machine.

---------------
With kind regards,
Dennis
Weekly Blog .NET & Excel: http://xldennis.wordpress.com/
My English site: http://www.excelkb.com/default.aspx
My Swedish site: http://www.xldennis.com/
Oct 26 '06 #11

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

7 posts views Thread by yuanlinjiang | last post: by
1 post views Thread by =?Utf-8?B?TWFyaW8=?= | last post: by
2 posts views Thread by Christian Muggli | last post: by
reply views Thread by zhoujie | last post: by
reply views Thread by suresh191 | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.