Outlook Add In (Exchange)- Create/Forward email - JavaScript - outlook

I have a problem with creating a script that creates/forwards an email in outlook to a constant recipiant.
the plan was to select keywords from checkboxes in its form. by pressing an inplemented button, the add-in should forward the opened email with a new subject from the checked checkboxes.
since i am very new to webdesign and js i would like to know if the idea could be realized without further ado. i have already browsed several forums and found out that sending email requires a web server and email client, which is out of the question due to the dynamic use and data security. also
I have already created the form of the add in. since this has no functions yet, i save posting a code/progress.
Any feedback?

OfficeJS doesn't provide anything for moving/forwarding items in Outlook. The web add-in is working under the currently selected item only. But you may consider using EWS or Graph API for implementing the required functionality.

Related

How to send an email from an outlook office add on?

I am trying to build an outlook add on, using react. I looked everywhere trying to find something that uses the mailbox in which the addon has been opened from, to programmatically send an email to a specified user.
Something similar to the google's command:
GmailApp.createDraft(e.parameters.address, e.parameters.subject, e.parameters.body, {
htmlBody: e.parameters.body,
name: 'Automatic Sender'
}).send();
Is the mail-sending process available on outlook?
Outlook web add-ins work under the context of currently selected item only. OfficeJS doesn't provide anything for creating and sending emails programmatically.
In Outlook add-ins you may consider using EWS, see Call web services from an Outlook add-in for more information. Also you may take a look at the Graph API as a possible workaround.

How to update an existing activity in WebChat

My scenario is: I send card attachments each with an AcceptButton to users. When 1 user clicks on that button, ideally I want to disable all similar buttons (of the same offer) for all users. I am storing conversation details of each user, and I know the ActivityId of each message-with-said-button (it follows a certain string format).
My issue is similar to this and this but for WebChat not Teams.
I did try those solutions but I got the error "Method not allowed" for both UpdateActivityAsync() and DeleteActivityAsync(). Then I read here that UpdateActivity is not supported in WebChat. (But might be available in the future?)
I would like any visual indication that the offer is no longer available. (Right now, they receive an "Offer was already accepted by {UserX}" which would still be in place on top of changing the card/message.)
Is there a way to do this via backChannel? I can trigger an event and pass the ActivityId (tested by showing a simple alert()) but how do I apply changes to that specific activity?
Per this comment in Web Chat's source code and this open issue in the Web Chat repository for adding support for deleteActivity and updateActivity, Update Activity events are not currently supported in Web Chat. Unfortunately, there is currently no way to really update an activity in Web Chat.
Hope this helps!

Microsoft Flow hyperlink not working in Outlook client

Good morning
I'm quite new to MS Flow and I came across an issue that I just can't find a solution for. I created a flow for an approval App in PowerApps and added a Link to the item on the email that is received by the person that needs to approve it. The problem is that the link to the item is not clickable in the Outlook 2016 client. It is in the OWA though, so there must be a setting to fix this (I hope).
Can someone please tell me what I'm doing wrong?
MS Flow Workflow
Outlook Client
If you meant by how to create a link with an href the add the below code in body of your email.
Click Here for details
Click the adavanced options from Send email flow and set 'Is HTML' property value to true.
For more information, please refer to these links:
How to insert a "Clck Here" in an email?
How do I get flow to stop encoding the ampersand in the href in my anchor tag?

Outlook Web Addin - Event handlers

I have a business requirement where there is a need to extend the functionality of outlook.
I am exploring Office Web Addins for this requirement.I have following queries.
I need to automatically move all incoming email to an external location.Does Office JS API provide handlers to incoming email event?
If it possible to define an action with Office JS API , which when triggered can loop through all the current unread emails and perform some action on each email (like move certain emails to a certain external location )
Is it possible to append custom headers to a email being composed using Outlook web add-in?
No
You can use EWS for that
No.
If your code only needs to run under the Windows version of Outlook, a COM addin might be a better option.
Unfortunately, it seems not possible to meet your requirements using Outlook Web Addin.
For more information, please review the following link: Outlook Add-ins overview

How can I add pulldowns and checkboxes in a MS Outlook email?

I want to create a small survey in an email message. The user are to respond using free form text boxes, check boxes , or pre-defined drop downlist . I see applications that claim to be able to do that. my needs are not that elaborate. Just a few questions that need to be asked
In Outlook 2007 there is functionality to create polls (Voting) which may satisfy your needs:
This feature requires you to use a Microsoft Exchange Server 2000, Exchange Server 2003, or Exchange Server 2007 account.
A demonstration is provided here.
You can simply include this as a normal HTML form in a mime part. See http://abiglime.com/webmaster/articles/cgi/010698.htm for how to do that.
However, many email clients will not display this. For example, in Thunderbird, there are settings for displaying message: "Original HTML", "Simple HTML", "Plain text". It will only display a form if it is set to "Original HTML".
Additionally, you may get security warnings from some email clients when trying to do the actual post from your email message over to the web site (I'm not sure about that as I've never tried).
I can see the appeal of making a survey easy to use in an email, but you should at least provide alternate links to access the survey on a website for users that can't see the form. And be sure to test this using a wide variety of email clients, eg: Thunderbird, Outlook, Outlook Express, Gmail, Yahoo, MSN/Hotmail,...
Cant you use HTML to make it work?
You can create a custom form within outlook that contains the controls you want. Use that form when creating a new email message. That will work.

Resources