outlook-addin

Unable to set item datetime (as PT_SYSTIME) using PropertyAccessor in Outlook VSTO

♀尐吖头ヾ 提交于 2019-12-23 23:18:47
问题 Setting a datetime column in Outlook to a c# DateTime value with the following code documentItem.PropertyAccessor.SetProperty( "http://schemas.microsoft.com/mapi/string/{00020329-0000-0000-C000-000000000046}/TestDate/0x0000001F", documentItem.PropertyAccessor.LocalTimeToUTC(DateTime.Now)); converts the columnvalue to type PT_APPTIME, which can't be displayed, sorted etc. in an Outlook-Tableview. All my tries to set the value as a PT_SYSTIME (eg. creating my own PROPVARIANT struct, Marshal

Outlook Web App (Exchange 2013 On-Premise) API 1.2 How to access Email Body?

痞子三分冷 提交于 2019-12-23 12:59:42
问题 Office.context.mailbox.item.body gives null while Office.context.mailbox.item.body.getAsync() works only with JavaScript API 1.3 . Is there any way to fetch email body with JavaScript API 1.1/1.2 ? 回答1: Yes you can. Actually, you will retrieve the body using Exchange Web Services. As explained here there are two ways to do this: 1) SOAP request from javascript (client app) or 2) server side using an SDK such as the .NET Exchange Web SDK For solution 1), your request could look like the

Outlook App - ADAL Authentication - AADSTS90056: This endpoint only accepts POST requests

不问归期 提交于 2019-12-23 10:58:27
问题 I'm working on an Outlook Add-in which authenticates the user against Azure AD and runs queries against SharePoint Online sites. The app uses AngularJS and makes use of the ADAL.js and ADAL-Angular.js libraries to conduct the authentication process. The app works well within the browser, however fails during the authentication process when used through the Windows Version of Outlook. Once the user inputs his username and password within the add-in in Outlook (Windows), and Internet Explorer

Cannot store and retrieve custom ItemProperties from AppointmentItem in case it is a recurring AppointmentItem

跟風遠走 提交于 2019-12-23 05:06:16
问题 I want to add some custom properties on an AppointmentItem. This works perfectly for "normal" AppointmentItems. Example: myAppointment.ItemProperties.Add("MyId", Outlook.OlUserPropertyType.olText, false, 1); MyId = (Outlook.UserProperty)myAppointment.ItemProperties["MyId"]; MyId.Value = myMeeting.id; meetingId = myMeeting.id; myAppointment.Save(); Even when I restart Outlook I can fetch those properties from the AppointmentItem like that: MyId = (Outlook.UserProperty)theCurrentAppointment

Set a MailItem as sent before calling SaveAs in Outlook Addin with C#

戏子无情 提交于 2019-12-23 02:46:20
问题 I am building an Outlook 2010 addin to integrate it with some business software and have trapped the ItemSend Event. I check if it is a MailItem and if it is I call the SaveAs function to save it as a .msg to the file system (in the users temp folder). void Application_ItemSend(object Item, ref bool Cancel) { if(Item is Outlook.MailItem) { Outlook.MailItem mailitem = (Outlook.MailItem)Item; string filename = "somefilename.msg"; string path = System.IO.Path.GetTempPath(); string fullPathName =

Get MessageID of a sent mail in Outlook

倾然丶 夕夏残阳落幕 提交于 2019-12-23 02:06:09
问题 I'm currently writing on an Outlook VSTO AddIn. Using this AddIn, I would like to keep track of E-Mail conversations and be able to uniquely identify mail messages. We are using Exchange as MTA. For all the mails in the Inbox (and many other folders) I can use the Message ID from the mail's header to do the matching, but mails lying in the "Sent Items" folder do not have a Message ID set. Is there a way to get the Message IDs from those mails? (I guess that the mails do not have a header, as

How to search for the name of the UserProperty in Outlook.MailItems, not their value

梦想与她 提交于 2019-12-23 01:08:06
问题 BACKGROUND: Currently I am searching Outlook.MailItems where their UserProperty (here, "IsProcessed") is equal to its propertyValue (here, true or false). string propertyValue = "true"; string filter = "http://schemas.microsoft.com/mapi/string/{00020329-0000-0000-C000-000000000046}/IsProcessed LIKE \'%" + propertyValue + "%\'"; I am using this filter string in advancedSearch link to doc PROBLEM STATEMENT: My usecase is to search if these mailItems have any UserProperty assigned where name of

How to tell when to use EWS vs rest API in Outlook Add-in

痞子三分冷 提交于 2019-12-22 18:20:13
问题 Is it possible to tell either in the XML file or through OfficeJs if the add-in can use the REST API or if it needs to use the older EWS API? We have an Outlook add-in that needs to support OWA/O365 and Outlook 2016 with a stand alone exchange server. We are wondering if it is possible through the manifest XML file or through OfficeJs to detect the configuration of users account so we can properly access their content with the correct API. The only alternative I can see is to provide two

Enable Outlook Web Add-in only on the Web

瘦欲@ 提交于 2019-12-22 14:00:10
问题 I developed an Outlook web-based add-in. To install it, I added the manifest file from the "Manage add-ins" page in OWA: https://msdn.microsoft.com/en-us/library/office/fp142256.aspx. The add-in is showing up in both Outlook Web App and Windows Desktop App. Is there a setting or code change need to be done to make the add-in available only in the Web App. 回答1: We have no such capability - we'd like the platform to provide users with consistent experience regardless of Outlook client/platform

C# Outlook add-in get selected emails

久未见 提交于 2019-12-22 07:06:09
问题 I want to get all selected emails in my Outlook 2010 add-in. I found this MSDN tutorial, but I am a beginner at C#, and I don't quite understand this line of code: Object selObject = this.Application.ActiveExplorer().Selection[3]; I believe Selection[] is something like overridden operator, indexer in C#. But, is there any way to see implementation of it? If I go through the code, I only see interfaces but not implementations. So I don't know the structure of the Selection object. What is