In this post, we will discuss how we can lookup To address from a SharePoint list while sending emails using SharePoint 2013 designer workflow. If you have put any static email id in the SharePoint designer workflow for sending emails, then any time you need to change the recipients, you must open the workflow in the Workflow Designer and make the changes manually. So it is better to look up the To or CC field from a list.
So first create a SharePoint custom list and the column which will contain the email id can be a Single line of text, Multiple lines of text, or Person or Group type columns. If you use a Person or Group column, only one entry can be made in each field that the workflow will reference for e-mail addresses. When creating the column, be sure to select No under Allow multiple selections. If you want to use this type of column to specify multiple recipients, you can create a SharePoint group that includes the people that you want the workflow to address the e-mail to, and then specify the group in the field. When creating the column, be sure to select People and Groups under Allow selection of.
In our case, we will create a column which will contain a single user. For user convenient rename the Title column to Workflow Name and other column say WorkflowToId. Then we will add one item to the list Where the Workflow Name=”My Test Workflow” and the WorkflowToIdfirstname.lastname@example.org and save the item. So the list with the item will look like below. Here Workflow Name is also important because we need to give this value in the designer workflow.
Now open your workflow in SharePoint designer 2013 and then click on the To icon to open the Select User dialog box. In the dialog box, click on “Workflow lookup for a User…”. This will open the Lookup for Person or Group dialog box. Here in the data source choose the list name that we made in above, and then Field from source the column name that contains the email id, in our case the column name is “WorkflowToId”. Then in the other section, choose Field as the Title column of the new list, in our case we rename it as “Workflow Name” and then in the Value box write the value presented for that column. In our case, it is My Test Workflow.
The dialog box will look like below:
After this, the email will be sent to the To address which is presented in the list. So afterward if you want to change the To email id, simply change in the list, no need to open the workflow. If you want to add more To address, then you can add additional columns and store and use like above.
You may like following SharePoint workflow tutorials:
- Package and Deploy workflow in SharePoint 2013 designer
- Change Item Level Permission using SharePoint designer workflow
- The Option for the SharePoint 2013 Workflow Platform is not available error in SharePoint 2013
- Workflow Internal Status Suspended error in SharePoint 2013
- SharePoint Designer 2010 Workflow Email Link To Edit Item or Display Item
- Set Text field to empty or blank in SharePoint 2013 designer workflow
- Set People Picker field to empty or blank in SharePoint designer workflow
- Approval Workflow in SharePoint Online with an example
- Three State Workflow in SharePoint with Example
Hope this SharePoint 2013 workflow tutorial explains lookup to address from SharePoint 2013 list in SharePoint 2013 designer workflow.
SharePoint Online FREE Training
JOIN a FREE SharePoint Video Course (3 Part Video Series)