Excel Automation Add-In, Accessing the application object

S

smedcalf

I am currently moving a VB6 Excel add-in(xla) over to a C# Automation
Add-In(dll). The previous code used Application.StatusBar to access and
manipulate the text in the status bar. How can this be done in my C# add-in?
Thanks.

Note: The only example i saw of accessing the Excel application was using
the following line:
object oName =
applicationObject.GetType().InvokeMember("Name",BindingFlags.GetProperty,null,applicationObject,null);
 
F

Fredrik Wahlgren

smedcalf said:
I am currently moving a VB6 Excel add-in(xla) over to a C# Automation
Add-In(dll). The previous code used Application.StatusBar to access and
manipulate the text in the status bar. How can this be done in my C# add-in?
Thanks.

Note: The only example i saw of accessing the Excel application was using
the following line:
object oName =
applicationObject.GetType().InvokeMember("Name",BindingFlags.GetProperty,nul
l,applicationObject,null);

The application object is passed to your add-in if you create a COM add-in.
This means you have to implement the IDTExtensibility2 interface.

http://msdn.microsoft.com/library/d...tro7/html/vxlrfIDTExtensibility2Interface.asp

Best Regards,
Fredrik
 

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