Firoz
Firoz

Reputation: 7454

Outlook Redemption : How to Access RDORules or rules from outlook in c#

I am using Outlook redemption to access all rules from outlook. How could we get RDORules using Outlook Redemption in c# ? I have tried accessing this using below code

Microsoft.Office.Interop.Outlook.Application app = new Microsoft.Office.Interop.Outlook.Application();
Microsoft.Office.Interop.Outlook._NameSpace ns = app.GetNamespace("MAPI");

Redemption.RDOSessionClass rdoSession = new Redemption.RDOSessionClass();
                rdoSession.MAPIOBJECT = ns.MAPIOBJECT;

rdoSession.Stores.DefaultStore.Rules - Here Rules property not exist.

The reason is rdoSession.Stores.DefaultStore return RDOStore object and Rules property exist in RDOExchangeStore object.

and i am not able to access RDOExchangeStore object. cause store kind is "skPstUnicode" Is there any way to access RDORules ?

Upvotes: 0

Views: 2733

Answers (1)

76mel
76mel

Reputation: 4043

Could be a couple of things up here .. have you iterated through the stores to find the exchange store ? as it looks like that you are not connected to exchange or the default store is configured to be a PST.

Update: to Answer your extra questions.

You can use RDO directly against the Exchange Server i.e Out side of outlook as long as you are online

Redemption.RDOSession rdoSession = new Redemption.RDOSession(); Use the logon method on the RDOSession object.

Upvotes: 0

Related Questions