cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
noldford
Level: Powered On

Using a shapreoint choice column to do conditional formatting

Hello,

 

I am trying to do some conditional formatting using a sharepoint choice column based on the selection having a column appear or not appear.  I can do this using a powerapps choice control by setting the visable parameter using the .selected.value= expression, however I can't get that to work with the sharepoint column.  Is there a way to do this?

 

Thanks for your any feedback!

 

Nick

1 ACCEPTED SOLUTION

Accepted Solutions
Community Support Team
Community Support Team

Re: Using a shapreoint choice column to do conditional formatting

Hi @noldford,

 

My understanding is that you want to make a column visible or not according to the selection of a Dropdown control. This Dropdown control should contain the options from a Choice column in SharePoint. If my understanding is correct, please follow below steps to achieve this:

1. Insert a dropdown control. set its Items property to:

Choices('ListName'.ChoiceColumnName)

Then you will the options of this dropdown control would be the option from Choices column in SharePoint.

 

2. Set the Visible property of the control that contains the data of the target column to:

If(Dropdown1.Selected.Value="xxx",true,false)

I just tested and this works for me:

Capture.PNG1.PNG

 

Regards,

Mona

Community Support Team _ Mona Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
4 REPLIES 4
Super User
Super User

Re: Using a shapreoint choice column to do conditional formatting

Hi @noldford,

Could you show a screenshot of what you are trying to accomplish.  Are you modifying a Datatable or Gallery control based on a Dropdown?  If you are trying to modify the choice column itself, it isn't as easy as it would seem.  Please review the following if that is the case.

 

https://powerusers.microsoft.com/t5/General-Discussion/Solved-patching-to-SharePoint-choice-and-look...

Community Support Team
Community Support Team

Re: Using a shapreoint choice column to do conditional formatting

Hi @noldford,

 

My understanding is that you want to make a column visible or not according to the selection of a Dropdown control. This Dropdown control should contain the options from a Choice column in SharePoint. If my understanding is correct, please follow below steps to achieve this:

1. Insert a dropdown control. set its Items property to:

Choices('ListName'.ChoiceColumnName)

Then you will the options of this dropdown control would be the option from Choices column in SharePoint.

 

2. Set the Visible property of the control that contains the data of the target column to:

If(Dropdown1.Selected.Value="xxx",true,false)

I just tested and this works for me:

Capture.PNG1.PNG

 

Regards,

Mona

Community Support Team _ Mona Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
noldford
Level: Powered On

Re: Using a shapreoint choice column to do conditional formatting

Hi Mona!

 

This is EXACTLY what I am looking to do.  This worked PERFECTLY and I can't express how much I appreciate that.  It was a major roadblock for projects.  Thank you all for your feedback, the patch way may have worked too but Mona's way is easier.

 

THANK YOU!

 

Nick

 

Super User
Super User

Re: Using a shapreoint choice column to do conditional formatting

@noldford,

 

Actually, you can simply use: Dropdown1.Selected.Value="xxx" without the If statement since it reduces to either true or false. 

 

 

Helpful resources

Announcements
firstImage

PowerApps Monthly Community Call!

Join us next Wednesday for our Demo Extravaganza, October 16, 2019 8am PDT.

firstImage

Microsoft Business Applications Virtual Launch Event

Join us for an in-depth look at the new innovations across Dynamics 365 and the Microsoft Power Platform.

firstImage

Watch Sessions On Demand!

Continue your learning in our online communities.

Power Platform 2019 release wave 2 plan

Power Platform 2019 release wave 2 plan

Features releasing from October 2019 through March 2020

FirstImage

Power Platform World Tour

Coming to a city near you

thirdimage

PowerApps Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

FourthImage

Join PowerApps User Group!!

Connect, share, and learn with your peers year-round

SecondImage

Power Platform Summit North America

Register by September 5 to save $200

Top Kudoed Authors
Users Online
Currently online: 555 members 5,954 guests
Recent signins:
Please welcome our newest community members: