top of page

We missed someone off the lottery syndicate !!

Oh no we missed someone off the National Lottery syndicate.


OOPS !


It is the last thing you want to have is missing someone off the syndicate, I felt really bad about it.  So I thought, I know, lets use flow to semi automate this process.


First of all I need a form, for people to opt in.  Microsoft Forms are very easy to do and I don’t think anyone would have much of an issue creating a one question page.


Once I had done that, I then had to build the trigger to get the responses from the form and initialize a variable:





Next you need to work through the response details, just search for the action “Get response details” and choose it from the list, the flow will automatically stick in an Apply to each loop so that every response gets picked up and actioned:





Next, the condition looks at whether the person has answered yes to opt in to the syndicate, of course they wanna play.  I mean who wants to loose out here right ?


So we need a “Start and wait for an approval” here, and the approval type is set to first to respond.  Now we could be clever here and set the syndicate managers at the top of the flow, but I have just left this hardcoded to myself and my friend.






If approved, I then update a spreadsheet on my one drive with the players names:





I then send a confirmation email to the person who wanted to be on the syndicate, and then send an email to myself and my colleague to say that they are on the list.


I then have a separate flow, which has recurrence as a trigger.  I love this flow, cos it is FIT.


We need all the players in by 12:45pm on the day of the draw, Tuesdays and Fridays so we can get down Barry’s Local News to buy the tickets.   Only playing for the big rollover days.  So the recurrence trigger starts on a Tuesday and a Friday at 13:00:





After this, I get the metadata from the xlsx document and the file content as per below:





I then send that document to my colleague and I with the spreadsheet attached:





But where is the FIT bit I hear you ask, ahhhh, here is the lovely part:


As the syndicate can potentially run twice a week, or maybe even once a month depending if there is a roll over or not, I need to clear down the spreadsheet so that we can start again.  Well here we go.


I put in a delay, to ensure that we receive the file, then I list the rows in the table and where the date is less than the time right now (utcnow() expression) then delete the rows.





Bobs your uncle, Fanny’s your aunt and Steve is your Grandma’s dog.


Love it.

56 views0 comments

Recent Posts

See All
bottom of page