cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Anonymous
Not applicable

How can I pass a toggle selection to a SharePoint edit form toggle for a YES/NO column?

I have a YES/NO column in a SharePoint list that uses custom text. I would like to use a PowerApps toggle to set the value on the YES/NO. However, when I submit a new item to the list, it does not show the value I selected using the toggle. How do I pass the toggle selection to the SharePoint List?

 

I know I probably need a variation on the following (which I do not understand but have used with much success) for a toggle like this:

 

{'@odata.type' : "#Microsoft.Azure.Connectors.SharePoint.SPListExpandedReference",
Id:Input.Selected.ID,
Value:Input.Selected.'List'
}

1 ACCEPTED SOLUTION

Accepted Solutions

Hi @Anonymous , 

 

For a Yes/No column, if you want to select Yes then you must send the value as true, or else send a false.
 
Now if you are using an Edit Form, please check you Update field is set to <<ToggleButton>>.Value 
 
If you are not using a Edit form, and want to patch the data out of a text Input and a toggle box, please refer to screenshot.
Patch(YashTest01,Defaults(YashTest01),{Title:TextInput1.Text,ToggleButton:Toggle1.Value})
Here YashTest01 is my SP list and Title & ToggleButton are its columns/attributes.MicrosoftTeams-image (50).png

 

If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up. THANKS!

View solution in original post

3 REPLIES 3

Hi @Anonymous , 

 

For a Yes/No column, if you want to select Yes then you must send the value as true, or else send a false.
 
Now if you are using an Edit Form, please check you Update field is set to <<ToggleButton>>.Value 
 
If you are not using a Edit form, and want to patch the data out of a text Input and a toggle box, please refer to screenshot.
Patch(YashTest01,Defaults(YashTest01),{Title:TextInput1.Text,ToggleButton:Toggle1.Value})
Here YashTest01 is my SP list and Title & ToggleButton are its columns/attributes.MicrosoftTeams-image (50).png

 

If this reply has answered your question or solved your issue, please mark this question as answered. Answered questions helps users in the future who may have the same issue or question quickly find a resolution via search. If you liked my response, please consider giving it a thumbs up. THANKS!

Anonymous
Not applicable

@yashag2255,

 

That worked! Thank you very much for your help.

Perfect! Happy that it worked for you. 

 

 

Helpful resources

Announcements
Ignite 2022

WHAT’S NEXT AT MICROSOFT IGNITE 2022

Explore the latest innovations, learn from product experts and partners, level up your skillset, and create connections from around the world.

Power Apps Africa Challenge 2022

Power Apps Africa Challenge

Your chance to join an engaging competition of Power Platform enthusiasts.

Top Kudoed Authors
Users online (1,975)