Ureader.com  
Microsoft software help and Community
   home   |   control panel login   |   archive   |  
 
Excel
123quattro
charting
crashesgpfs
datamap
excel
interopoledde
links
misc
newusers
printing
programming
querydao
sdk
setup
templates
worksheet.functions
  
 
date: Thu, 8 Dec 2005 14:48:50 -0800,    group: microsoft.public.excel.interopoledde        back       


Interop with OLE Control   
Hi there,

I am trying to use a COM object (written in C++) from an Excel add-in in C#.
So far, in every directions I looked, I have been unable to access the
properties of my COM component. Here is what I did:

- use Interop conversion
- instantiate the class
- try to access the properties (which are visible for Intellisence) ->
exception "catastrophic error"
- get the list of properties (by gettting the Type and calling
GetProperties), my properties are visible, use InvokeMember to set or get my
properties: an exception is thrown.

My COM component is valid (very simple, and visible from Excel throught the
"More Control" option of the toolbox. When I instantiate the component this
way, the properties are visible and accessible (i.e. I can modify them)
through the property panel of my OLEObject.

I am quite conviced this is possible, and that I am missing something
obvious. Any guess?

Thanks,

Marc
date: Thu, 8 Dec 2005 14:48:50 -0800   author:   Marc ail

Google
 
Web ureader.com


    COPYRIGHT 2007, YARDI TECHNOLOGY LIMITED, ALL RIGHT RESERVE  |   contact us