Obtaining List of AddIns - Late binding (Excel)

R

RM

I am trying to obtain the list of AddIns and their fullnames from Excel. I
am using late binding. I would like to do something like:

objApp_AddIns = (object [])objApp_Late.GetType().InvokeMember( "AddIns",
BindingFlags.GetProperty, null, objApp_Late, null );
foreach (object objAddIn in objApp_AddIns)
{
object fullName = objAddIn.GetType().InvokeMember( "FullName",
BindingFlags.GetProperty, null, objAddIn, null );
}

This, however, throws a runtime exception on the cast.

Any ideas/suggestions on how I might do this differently. I cannot use any
of the Interops.


Thanks,

RM.
 

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