A Microsoft Outlook email forum. Outlook Banter

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » Outlook Banter forum » Microsoft Outlook Email Newsgroups » Add-ins for Outlook
Site Map Home Register Authors List Search Today's Posts Mark Forums Read Web Partners

Tags: , , ,

Calling an Add-in method from another Application





 
 
Thread Tools Display Modes
  #1  
Old March 12th 07, 05:51 PM posted to microsoft.public.outlook.program_addins
David
external usenet poster
 
Posts: 6
Default Calling an Add-in method from another Application

http://www.microsoft.com/communities...4-19e70f3a855c



My application that attempts to use the externally available call can't seem to get hold of the add-in.
I get the following exception:
System.Runtime.InteropServices.COMException (0x80010001): Call was rejected by callee. (Exception from HRESULT: 0x80010001 (RPC_E_CALL_REJECTED))

The calls I am making a
Outlook.ApplicationClass olApp = new Outlook.ApplicationClass();
Outlook.NameSpace olNS = olApp.GetNamespace("MAPI");
MSOffice.COMAddIns addIns = olApp.COMAddIns;

I do not get the error if Outlook is running before my application starts.

I suspect this is something to do with me trying to access the AddIn before it is loaded - does that sound plausable?

Any thoughts on what I should do?

Thanks
Ads
  #2  
Old March 17th 07, 07:33 PM posted to microsoft.public.outlook.program_addins
Ken Slovak - [MVP - Outlook]
external usenet poster
 
Posts: 3,778
Default Calling an Add-in method from another Application

Test your hypothesis.

What happens if you use a timer or something to delay checking for the
addins until ActiveExplorer() isn't a null object? Or if you wait say 30
seconds?

--
Ken Slovak
[MVP - Outlook]
http://www.slovaktech.com
Author: Absolute Beginner's Guide to Microsoft Office Outlook 2003
Reminder Manager, Extended Reminders, Attachment Options
http://www.slovaktech.com/products.htm


"David" wrote in message
...

http://www.microsoft.com/communities...4-19e70f3a855c



My application that attempts to use the externally available call can't
seem to get hold of the add-in.
I get the following exception:
System.Runtime.InteropServices.COMException (0x80010001): Call was
rejected by callee. (Exception from HRESULT: 0x80010001
(RPC_E_CALL_REJECTED))

The calls I am making a
Outlook.ApplicationClass olApp = new Outlook.ApplicationClass();
Outlook.NameSpace olNS = olApp.GetNamespace("MAPI");
MSOffice.COMAddIns addIns = olApp.COMAddIns;

I do not get the error if Outlook is running before my application starts.

I suspect this is something to do with me trying to access the AddIn
before it is loaded - does that sound plausable?

Any thoughts on what I should do?

Thanks

 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Calling an Add-in method from another Application Anyone for Coffee? Add-ins for Outlook 0 March 10th 07 02:16 AM
Calling an Add-in method from another Application David Add-ins for Outlook 4 March 10th 07 12:09 AM
Calling exposed add-in method and handeling _ComObject type? Preky Add-ins for Outlook 0 September 7th 06 01:45 PM
'Display Name' Property for Attachments.Add Method Ned Moorfield Outlook and VBA 0 May 18th 06 10:06 AM
about CItems's Add method??? StupidDog Outlook - Using Forms 0 April 19th 06 12:15 PM


All times are GMT +1. The time now is 01:47 AM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.Search Engine Friendly URLs by vBSEO 2.4.0
Copyright ©2004-2008 Outlook Banter, part of the NewsgroupBanter project.
The comments are property of their posters.
Gas Suppliers - Buy Anything On eBay - Free Ringtone - Mortgage Calculator - Debt Consolidation