Dear All,
We have create Desktop application which is Microsoft office & windows interoperability. Where we created templates in Word, Powerpoint, excel & access, windows & outlook.
In templates we have PreActions & PostActions. These actions are performing well in all templates, except, outlook templates.
The outlook templates PreActions are only working, if visual studio is running. When we are publishing this on live server, but, it is not working on clients machine, where as other templates are working.
What I have tried:
For Example: Create Draft mail[PreAction]
public static bool CreateDeleteEmail(string to, string cc, string bcc, string subject, string body)
{
using (RdoSessionWrapper rdoSession = new RdoSessionWrapper())
{
RDOFolder deleteFolder = rdoSession.RdoSession.GetDefaultFolder(rdoDefaultFolders.olFolderDeletedItems);
RDOMail mailItem = deleteFolder.Items.Add();
mailItem.SenderEmailAddress = Resources.OutlookExamEngineMapiPop3AccountName;
mailItem.SenderEmailType = "SMTP";
mailItem.To = to;
mailItem.CC = cc;
mailItem.BCC = bcc;
mailItem.Subject = subject;
mailItem.Body = body;
mailItem.Importance = (int)OutlookInterop.OlImportance.olImportanceNormal;
mailItem.UnRead = true;
mailItem.Save();
return true;
}
}
The above is working, if its running locally but not on client's machine.
Can any one please help me.
Thanks in advance.