Manikandan
Guest
|
Hi All,
I couldn't able to retrieve Embedded image using Ribbon menu for Outlook Enterprise Vault Archived Emails.
I have used below code,
public void ReplyAllWithAttachment(Office. IRibbonControl control)
{
ReplyWithAttachments( true );
}
public void ReplyWithAttachments( bool isreplyall)
{
Outlook. MailItem rpl;
object item;
item = GetCurrentItem();
try
{
if (item != null )
{
Outlook. MailItem mailItem = item as Outlook. MailItem ;
rpl = (Outlook. MailItem )mailItem.Reply();
CopyAttachments(mailItem, rpl);
rpl.BodyFormat = Outlook. OlBodyFormat .olFormatHTML;
rpl.Display();
rpl = null ;
item = null ;
}
}
catch ( Exception ex)
{
WriteLog(ex.ToString());
}
}
public object GetCurrentItem()
{
Microsoft.Office.Interop.Outlook. Application objApp = new Microsoft.Office.Interop.Outlook. Application ();
object GetCurrentItem = null ;
object activeWindow = objApp.ActiveWindow();
try
{
if (activeWindow!= null )
{
Outlook. Explorer explorer = activeWindow as Outlook. Explorer ;
Outlook. Inspector inspector = activeWindow as Outlook. Inspector ;
if (explorer != null )
{
GetCurrentItem = objApp.ActiveExplorer().Selection[1];
}
else if (inspector != null )
{
GetCurrentItem = objApp.ActiveInspector().CurrentItem;
}
}
}
catch ( Exception ex)
{
WriteLog(ex.ToString());
}
return GetCurrentItem;
}
By defualt mailitem bodyformat properties is olFormatRichText for Enterprise Vault Archived Email.
Please any one help me how to retrieve embedded image for Enterprise Vault Archive Email(olFormatRichText )?
Thanks in Advance. |
|
Eugene Astafiev
Guest
|
|
Manikandan
Guest
|
Hi Eugene,
I have created the Ribbon Menus using Ribbon XML to my project.
Please find the below code,
<?xml version="1.0" encoding="UTF-8"?>
<customUI xmlns="http://schemas.microsoft.com/office/2009/07/customui" onL oad="Ribbon_Load">
<ribbon>
<tabs>
<tab idMso="TabReadMessage">
<group id="grpRespond"
label="Respond with Attachment" insertBeforeMso="GroupShow" >
<button id="textButton" label="Reply with Attachment" getImage="GetImage" size="large"
screentip="Reply with Attachment" onAction="ReplywithAttachment"
supertip="Reply to the sender with attachment of this message." getEnabled="IsVisible"/>
<button id="tableButton" label="Reply All With Attachment" getImage="GetImage" size="large"
screentip="Reply All With Attachment" onAction="ReplyAllWithAttachment"
supertip="Reply to the sender and all other recipients with attachment of this message." getEnabled="IsVisible"/>
</group>
</tab>
</tabs>
</ribbon>
</customUI>
I'm not using Ribbon Designer for Microsoft??? SharePoint??? and Office 365 for my project. |
|
Eugene Astafiev
Guest
|
Hi Manikandan,
Okay. What our product do you use? |
|
Manikandan
Guest
|
Hi Eugene,
My Requirement is Reply/Reply to All with original attachments in outlook 2010 using Outlook Add-In application.
I'm using Microsoft Outlook 2010 and MS visual studio 2010(c#). |
|
Eugene Astafiev
Guest
|
|
Eugene Astafiev
Guest
|
You are welcome, Manikandan! :-) |
|