Read our blogs, tips and tutorials
Try our exercises or test your skills
Watch our tutorial videos or shorts
Take a self-paced course
Read our recent newsletters
License our courseware
Book expert consultancy
Buy our publications
Get help in using our site
548 attributed reviews in the last 3 years
Refreshingly small course sizes
Outstandingly good courseware
Whizzy online classrooms
Wise Owl trainers only (no freelancers)
Almost no cancellations
We have genuine integrity
We invoice after training
Review 30+ years of Wise Owl
View our top 100 clients
Search our website
We also send out useful tips in a monthly email newsletter ...
Software ==> | Power Automate (21 exercises) |
Topic ==> | Apply to each loops (3 exercises) |
Level ==> | Average difficulty |
Subject ==> | Power Automate and PAD training |
This exercise is provided to allow potential course delegates to choose the correct Wise Owl Microsoft training course, and may not be reproduced in whole or in part in any format without the prior written consent of Wise Owl.
This exercise gets you to inspect any drink ordered through SharePoint. If it's a valid drink, you'll add it to an Excel sheet; otherwise, you'll email the orderer to say they can't have this and invite them to choose something else.
Start by uploading the Excel workbook in the above folder into OneDrive:
Choose to upload the workbook of drink orders in the above folder.
Now create a new SharePoint list:
Choose to add a new list to a Sharepoint site of your choice.
Add this list from Excel, and choose the workbook in the above folder:
Choose to add your list from Excel, then choose to upload your list from the Excel workbook in the above folder.
Choose to load the SharePointList table and call this list DrinkOrders:
The data you should load.
Add a new Power Automate flow which is triggered when someone adds a new drink to this list.
Add an action to initialise a variable to the drinks served up by the (imaginary) Wise Owl drinks machine:
Set the variable to hold an array of 3 drinks.
If this was a real flow you might have stored the names of these allowed drinks in an Excel table or Sharepoint list and read this into the array instead (this would make it easier to add drinks if your dispensing machine should ever be upgraded).
Add a conditon that the drink just added is in the array of allowed drinks:
The moment you select this, Power Automate will add an Apply to each loop (presumably because it's looping over all of the Sharepoint items just added?).
Add actions as follows:
Condition value | Action |
---|---|
True | Add a row into the table called Orders in the Excel file you uploaded at the start of the exercise, setting the column values correctly for who ordered the drink, what it was and the milk and sugar choices. |
False | Send an email to the person who created the order item saying that the Wise Owl dispenser doesn't contain their drink. |
Here's what your final flow should look iike:
The final flow should look something like this.
Test out your flow. If you order one of the proscribed drinks (a Malibu say) you should get this email:
Unsurprisingly ...
If on the other hand you order one of the prescribed drinks, you should get a new row in your Orders table in Excel:
Start making this drink!
A final question to mull over: what would have been the best way to design this flow?
You can find other training resources for the subject of this exercise here:
Kingsmoor House
Railway Street
GLOSSOP
SK13 2AA
Landmark Offices
99 Bishopsgate
LONDON
EC2M 3XD
Holiday Inn
25 Aytoun Street
MANCHESTER
M1 3AE
© Wise Owl Business Solutions Ltd 2024. All Rights Reserved.