Forum Discussion

ikoalosaurus's avatar
ikoalosaurus
Copper Contributor
Jul 16, 2019
Solved

Updating specific List Column value with Flow?

Is it possible to use flow to update specific value in an item in a specific list column?

  • ikoalosaurus  Yes, that's doable, but why would you want to do that? Why spam someone with dozens of emails about people starting or ending their shifts?? How will the receiver of these emails get an overview of the big picture?

     

    Wouldn't it make more sense to give that receiver of the emails a view where they can see who is currently on shift and who is not? That would be just a list view that they can pull up at any time, and they don't have to find and interpret the two dozen emails they have been sent from a workflow during the day. 

     

    Also, if you set the default view of the list to be filtered so people can only see the items where the <shift person> column equals [Me], they can just pull up the list, see their own record and edit it. That will greatly reduce the probability of Mark accidentally editing the item for Jane. You can also turn on versioning, so each and every item change can be traced back to who made the change.

     

    You can create a site page for supervisors. This page can have a list view that shows all items, grouped or sorted by who is on shift. Set the permissions for this page so only a certain group of people can access it. That way, your regular Jane Bloggs will not easily be able to look at other people's shifts. It's not fool proof, but it requires quite a bit of SharePoint knowledge to unravel and expose,

15 Replies

  • Damien_Rosario's avatar
    Damien_Rosario
    Silver Contributor

    Hi ikoalosaurus 

     

    I've put together a simple example flow I hope fits with your scenario (see instructions and images below).

     

    STEP 1 - Add When an item is created or modified

    STEP 2 - Add a Condition and add the Person field attribute from your list as the first condition (left) and the Modified By Email (right). This will check if the person changing the line item is actually theirs or someone else is doing it.

     

    STEP 2A - If the person matches their line item (Condition - YES)

    Add another Condition with the Yes/No field (left) is equal true.

     

    If Condition 2 is True, you could send an email off to the supervisor letting them know when this person has checked in or if Condition 2 is False, you can email that the person has gone off duty.

     

    STEP 2B - If the person does not match the line they are changing (Condition - NO)

    Use Get Item to retrieve the list data using Dynamic content ID from When an item is created or modified.

     

     

    STEP 2B1 - Add another Condition with the Yes/No field (left) is equal true is equal to true. This will check to see what the user has incorrectly changed the field to.

     

     

    If Condition 3 is True, switch the Yes/No field back to No. If Condition 3 is False, switch the Yes/No field back to Yes

     

    I do this because if the user has incorrectly changed someone else's Yes/No field, I want it restored back to the original setting before they touched it.

     

    You could send an email off to the supervisor letting them know if the wrong person tried to change the field of another freelancer.

     

    STEP 2B2 - Add Terminate to stop the flow so it doesn't loop forever changing the properties of the list. 

     

    I hope that makes sense and is helpful. My interpretation of what I would do in your scenario.

     

    Cheers

    Damien

  • ikoalosaurus  Yes.

     

    Conceptually, you use the Get Items action to get a list of the items. Use the filter settings to return only the items you want to change. Then use a for-each action to update each item.

    • ikoalosaurus's avatar
      ikoalosaurus
      Copper Contributor

      IngeborgHawighorst 

       

      Thank you.

       

      This is what i'm trying to do. 

      There is a column of type yes/no, called "Available now" in my schedule shift list that i created.
      I need a flow which will do something like this:

      -Either automatically update the field to Yes of each worker when they do a trigger (which could be sending an email to a specified mailbox for example, or alternatively something else)

      -Or, people click on the list with their item name, change the value from no to yes, and then flow sends an email to a specified mailbox.

       

       

      Could you somehow help me how to achieve this?

       

      Thank you 

      • ikoalosaurus  Both things you describe are possible, the latter is a bit easier, since the trigger is when a SharePoint list item is modified. I'm not so clear on the trigger for the other option.

         

        Before we proceed, maybe you could make a decision about which approach you want to use?

Resources