Abstract
Many of the InfoPath applications that I write involve notification emails and workflows as in the previous chapter. In most cases, however, we want to notify an entire office or workgroup rather than a specific individual. A useful technique is to have each office in a custom SharePoint list. Figure 138 shows the layout of the Office Members list. Anyone in this list will have permissions for their office’s section of the form. Notice that the Member Name column is of type Person or Group. We display its Account field so that when we reference it from InfoPath, it will match up with its userName() function. Later, we will use SharePoint’s REpresentational State Transfer (REST) service to read this same list in order to send notification emails to only those members that have a SendNotificationEmails column set to true. While we are at it, we give each user the option for giving one or more AlternativeEmailAddress rather than using the one associated with their SharePoint account.
Access this chapter
Tax calculation will be finalised at checkout
Purchases are for personal use only
Notes
- 1.
- 2.
This gives an easy way for the office to control notifications based on whether someone is in the office. Note that avoiding spaces in the column names is easier since each space needs an encoded _x200_ when using it with REST. Keep them relatively short as well to avoid issues when the names are being truncated.
- 3.
Chrome will display the XML as well but not in a formatted state. In that case, you can paste the results into an XML editor such as Visual Studio.
- 4.
This is important for us at the Air Force Academy because some users have both an “EDU” and “MIL” address. A SharePoint 2013 will only email to the primary account associated with SharePoint, but the 2010 can go to either one (as well organizational email addresses).
Author information
Authors and Affiliations
Rights and permissions
Copyright information
© 2019 Jeffrey M. Rhodes
About this chapter
Cite this chapter
Rhodes, J.M. (2019). Using SharePoint REST Services to Control Email Notifications. In: Creating Business Applications with Office 365. Apress, Berkeley, CA. https://doi.org/10.1007/978-1-4842-5331-1_20
Download citation
DOI: https://doi.org/10.1007/978-1-4842-5331-1_20
Published:
Publisher Name: Apress, Berkeley, CA
Print ISBN: 978-1-4842-5330-4
Online ISBN: 978-1-4842-5331-1
eBook Packages: Professional and Applied ComputingApress Access BooksProfessional and Applied Computing (R0)