cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
New Member

Select choices by clicking on buttons

Hi Guys,

 

I have aSharepoint List with Choices type field called Status withchoices (unprocessed, for Sales Approval, for Confirmation, for Prepayment, for Shipment, for Invoicing, finished)  I use a PowerApps form to edit the list items. However users can select only a few items of Status for new value of Status based on the current value of Status.

Eg: Current choice : "unprocessed", new choices can be only "for Confirmation" or "for Sales Approval" or "for Prepayment".

if the Current choice  is "for Sales Approval" the new choices can be only "for Confirmation" or "for Prepayment" and so on. 

 

I placed buttons for each choices on the DataCard of Status which are visible based on current status. So far so good.

But how can I change the status clicking on one of the visible Buttons ?

  

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Super User III
Super User III

Re: Select choices by clicking on buttons

@CsaszarZsomle 
Place this code inside the OnSelect property of the 'for Confirmation button.  When the button is pressed it will change the status.

Patch(your_sharepoint_list, ThisItem, {Status = {Value: "for Confirmation"}});

 

Repeat as necessary for the other buttons while changing the status text.

 

---
Please click "Accept as Solution" if my post answered your question so that others may find it more quickly. If you found this post helpful consider giving it a "Thumbs Up."

View solution in original post

2 REPLIES 2
Highlighted
Super User III
Super User III

Re: Select choices by clicking on buttons

@CsaszarZsomle 
Place this code inside the OnSelect property of the 'for Confirmation button.  When the button is pressed it will change the status.

Patch(your_sharepoint_list, ThisItem, {Status = {Value: "for Confirmation"}});

 

Repeat as necessary for the other buttons while changing the status text.

 

---
Please click "Accept as Solution" if my post answered your question so that others may find it more quickly. If you found this post helpful consider giving it a "Thumbs Up."

View solution in original post

Highlighted
New Member

Re: Select choices by clicking on buttons

So simple and works well 🤗

Helpful resources

Announcements
Community Conference

Power Platform Community Conference

Find your favorite faces from the community presenting at the Power Platform Community Conference!

Watch Now

Experience what’s next for Power Apps

See the latest Power Apps innovations, updates, and demos from the Microsoft Business Applications Launch Event.

Power Platform ISV Studio

Power Platform ISV Studio

ISV Studio is designed to become the go-to Power Platform destination for ISV’s to monitor & manage published applications.

secondImage

Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

Top Solution Authors
Top Kudoed Authors
Users online (9,134)