outlook-addin

Office Add-in Outlook API attach document using displayNewMessageForm method issue

扶醉桌前 提交于 2019-12-04 17:48:16
I'm working on office Add-in for Outlook. Need to open a new message with a pre-defined attachment. Trying to get an attachment from the current item (message) as below: Office.context.mailbox.item.attachments Here is an output (i get attachment type, id, size and so on): Then I'm trying to attach this file to a new message in Outlook via add-in outlook API, here is an example from Office Developer that I use to attach the file I just get from the other email (like 'forward' functionality): Office.context.mailbox.displayNewMessageForm( { toRecipients: Office.context.mailbox.item.to, // Copy

How to loop through all MailItems of certain Outlook subfolders

淺唱寂寞╮ 提交于 2019-12-04 12:47:48
I'm working on an Outlook 2007 add-in. I found some code to loop through all the folders but I have not been able to figure out how to loop inside any given folder to examine the MailItem objects (ultimately, I want to save the emails elsewhere and modify the .Subject property). Here is what I have so far: private void btnFolderWalk_Click(object sender, EventArgs e) { // Retrieve the name of the top-level folder (Inbox) , for // the purposes of this demonstration. Outlook.Folder inbox = Application.Session.GetDefaultFolder(Outlook.OlDefaultFolders.olFolderInbox) as Outlook.Folder; // Cast the

The type 'UserControl' does not support direct content

女生的网名这么多〃 提交于 2019-12-04 08:47:46
问题 I have an Outlook 2013 and 2016 VSTO Add-in project and am trying to add a WPF user control to a custom task pane as described here. The problem I have is when I add the User Control (WPF) it generates me a WPF control with a grid, but automatically throws an error of "The type 'UserControl' does not support direct content". WPF generated: <UserControl x:Class="TestNamespace.UserControl1" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com

Uncaught TypeError: Cannot read property 'Version' of null in outlook-web-16.01.js

末鹿安然 提交于 2019-12-04 08:34:11
outlook-web-16.01.js:13 Uncaught TypeError: Cannot read property 'Version' of null at Object.callback (outlook-web-16.01.js:formatted:4686) at rt (outlook-web-16.01.js:formatted:4272) This is what I get when I tried to use Office.context.auth.getAccessTokenAsync(function (result) { After overriding everything inside <VersionOverrides xmlns="http://schemas.microsoft.com/office/mailappversionoverrides/1.1" xsi:type="VersionOverridesV1_1"> problem has solved. <VersionOverrides xmlns="http://schemas.microsoft.com/office/mailappversionoverrides" xsi:type="VersionOverridesV1_0"> ...

ItemAdd event on a public folder on Exchange

痴心易碎 提交于 2019-12-04 08:11:37
I have a problem with attaching an event handler to an ItemAdd event of a public folder. The problem is the event handler stops being called after a few successful calls. The code is trivial. I have a ThisAddIn class which creates an object which in turn attaches a function to the ItemAdd event in its constructor. The function just pops up a messagebox. Please point me in the right direction. I simply don't understand where to look for the error. Thank you in advance, Anatoly Here is the test code I try to run: public partial class ThisAddIn { internal static Outlook.Folder posts_folder = null

adding Outlook 2013 mailitem contextmenu. VS 2012 C#

…衆ロ難τιáo~ 提交于 2019-12-04 08:02:07
Hi i want to add a new button to outlook 2013 mailitem contextmenu. I use VS 2012 C#. I seached internet but cant find a way to do this, im upgrading an Outlook 2010 addin which modified the contextmenu. In visual studio on project select add new item. Choose Ribbon(XML). add following to XML file: <contextMenus> <contextMenu idMso="ContextMenuMailItem"> <menu id="ArcIT" label="ArcIT"> <button id="MyContextMenuMailItem" label="ContextMenuMailItem" onAction="OnMyButtonClick"/> </menu > </contextMenu> </contextMenus> in ribbon.cs class add following method public void OnMyButtonClick(Office

change outlook MailItem icon

こ雲淡風輕ζ 提交于 2019-12-04 06:22:29
I'm developing an outlook 2010 addin that exports the emails to a specific locations when an user clicks a button from the menu. This part is not a problem, but I need also to change the MailItem icon-pictogram if the export was successful. I tried to look for solutions, but I only get that I need to use form regions , but I didn't find a true helpful solution. Any ideas how should I use this form regions?! I finished the add-in and everything seems to work perfect when debugging from VS 2010. I also created an installer, but after installing the application the Outlook won't display my icons

Outlook Redemption - using RedemptionLoader without regsvr32 the DLL

醉酒当歌 提交于 2019-12-04 06:14:25
问题 I want to use the mail functions without registering the COM dll (regsvr32). I followed the informations from: http://www.dimastr.com/redemption/security.htm#redemptionloader so i initialize the dll with private Redemption.SafeMailItem safeMail = Redemption.RedemptionLoader.new_SafeMailItem(); which shows the Eval-Popup. All good. But when i assign the outlook mail item to the object safeMail.Item = mail; // of type Microsoft.Office.Interop.Outlook.MailItem then this exception appears: Unable

Invoke 3rd party Outlook AddIn-Button from my AddIn

六眼飞鱼酱① 提交于 2019-12-04 05:52:11
问题 I'm looking to create an AddIn for outlook which will invoke an Attach and Forward function from another 3rd party addIn when a mail item is added to a certain folder, however I'm not sure how to find this button in order to invoke it. the desired button is displayed on the inbox screen (when mail is selected bottom left) but not when a mail is opened (double click) is in a drop-down, here's the structure. Highlighted is the desired function. How would I invoke this function for a specific

ics file not recognized by outlook

走远了吗. 提交于 2019-12-04 05:21:30
问题 I have some problems. I'm trying to send an ics file, so an outlook user can add the event in his calendar. In some versions, like 2010, it works well (home edition) but on some, (like business) it doesn't recognize it directly. You must double-click the content so you can preview it. In that other version, it shows the calendar option immediately as I've clicked the mail. What am I doing wrong? Here is the code for the calendar. $str="BEGIN:VCALENDAR\r\n PRODID:-//Microsoft Corporation/