问题
It possible to change message body (e.g. add some text at the end) on send button clicking.
回答1:
Outlook 365? There is no such thing. Do you mean Outlook 2016 (desktop app)? Or Outlook Web App?
In the former case, trap the Application.ItemSend
event and modify the message passed as the parameter.
In the latter case, there is nothing you can do.
回答2:
Office.js API currently doesn't support events. There are a lot of requests for monitoring "onSend" event. You may up vote it over here: officespdev.uservoice.com.
Meanwhile you may need to consider re-design your application to change message body at the time of add-in invocation by user. To manipulate with the body of the message Office.js API provides plenty of functions: Office.context.mailbox.item.body
EDIT:
On send feature for Outlook add-ins was implemented with lots of limitation, but at least it's there. Outlook add-in on send code sample is available as well.
来源:https://stackoverflow.com/questions/43095378/change-message-body-before-sending-in-outlook-365