Automatically Send Emails From A Queue

Fredrik Engseth
7 min readOct 25, 2022

Introduction

When creating and sending an email from Dynamics 365, the default functionality will populate the “From” field with the user creating the email. Depending on a user’s role within the organization, if they work on a team managing cases or other shared work, emails may need to all come from one email address. The user’s email address needs to be accurate in the system so we can’t change that, but we can use a queue to send emails rather than the user.

When creating an email from a case the email will be populated with the “Regarding” case. And, if the case is added to a queue we can retrieve the queue item and use the queue related to the case. Instead of populating the user in the “From” field, we can use JavaScript to set the queue in the “From” field when the form is loading.

In this post, we look at how we can do that.

Table of Content

Prerequisites

  • Setting up a Trial Environment
  • The Goal of the Post
  • How to Automatically Send Emails From a Queue

Prerequisites

  • Familiar with JavaScript
  • Familiar with Dynamics 365
  • Familiar with the Power Platform

--

--

Fredrik Engseth

Developer | Dynamics 365 | Power Platform | Azure | Personal development | Investments | ☕ https://www.buymeacoffee.com/fredrikengseth