cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Flensborg
Frequent Visitor

Can not save because of a hidden required field

Hello,

I am building a SharePoint list using Power Apps to help input correct data. 

I have created a dropdown that is visible if Type Of Project = Execution Project

If it not an Execution Project, the selected dropdown will be hidden.

 

However the drop-down is mandatory, and I would like it to be mandatory only if visible. 

Currently I am not able to save if I select something that isn't  Execution, as the required field is now hidden.

 

How do I ensure that this drop-down is required ONLY if DataCardValue18.Selected.Value = "Execution Project"?

 

I've tried the following: If(DataCardValue18.Selected.Value = "Execution Project",true,false) 

I have also tried making two statements

If(DataCardValue18.Selected.Value = "Execution Project",true) OR If(DataCardValue18.Selected.Value = "New Product Development",false)

Flensborg_0-1656081587109.png

 

However I do not seem to be able to crack this. Does anyone have any ideas?

 

1 ACCEPTED SOLUTION

Accepted Solutions

Thanks for the answer. I had already changed the permissions in the SharePoint column, but apparently PowerApps had not registered it. 

The solution for me was to re-create the exact same column, and then do as you mentioned with making it "required" in PowerApps and "Not Required" in the SharePoint list settings.

 

Thanks for your help 🙂

View solution in original post

2 REPLIES 2
VeGETzX
Resolver III
Resolver III

As I know, If your SharePoint column are required, So the data for that column can't be blank, regardless of any code you use on Power Apps because it's restricted by SharePoint.

 

I do recommend to set that column to be optional on that SharePoint list and use Required property for Datacard in PowerApps.

 

It's more flexible, then you can use this code on Required property of your Execution Project's datacard 

DataCardValue18.Selected.Value = "Execution Project"

Thanks for the answer. I had already changed the permissions in the SharePoint column, but apparently PowerApps had not registered it. 

The solution for me was to re-create the exact same column, and then do as you mentioned with making it "required" in PowerApps and "Not Required" in the SharePoint list settings.

 

Thanks for your help 🙂

Helpful resources

Announcements
Microsoft 365 Conference – December 6-8, 2022

Microsoft 365 Conference – December 6-8, 2022

Join us in Las Vegas to experience community, incredible learning opportunities, and connections that will help grow skills, know-how, and more.

Power Apps Ideas

Check out the New Ideas Site

We are excited to announce a new way to share your ideas for Power Apps!

Top Solution Authors
Top Kudoed Authors
Users online (3,310)