Announcements
I got a question.
I'm building an app and there I have multiple fields which should be mandatory fields but only if they are visible. So that i can press the "Submit"-Button only if the visible fields are filled with content.
I hope anyone can help me solving this problem.
Best greetings
PowerAppsUser
Ok, try this:
If(
IsBlank(Field1.Text) || IsBlank(Field2.Text),
//Fields need information, they are blank ,
//You can submit
)
If you need additional help please tag me in your reply and please like my reply.If my reply provided you with a solution, pleased mark it as a solution ✔️!Best regards,Gonçalo NogueiraCheck my LinkedIn!My website!My blog!
Hi @PowerAppsUser5,
I guess you can achieve that with the use of DisplayMode property of your submit button:
If( TextControl.Visible = true And IsBlank(TextControl.Text), DisplayMode.Disabled, DropDownControl.Visible = true and IsBlank(DropDownControl.Selected)), DisplayMode.Disabled, //You can add as many conditions as you like DisplayMode.Enabled )
You can set the Required attribute in the Datacard and handle it somewhat that way but to truly handle it within a form isn't really a thing i have for that reason two diffrent sharepoint lists (only if you use sharepoint are any of my said things in context). Then i set the visability dependent on the requirements (with the other method i was able to submit null values if somehow the datacard didn't update properly (possibel inconsistency issue only on super rare events but it happens)).
I tried one solution and I think it's a good one but there's still any mistake.
In the added picture you can see what I've done. I tink the mistake is somewhere at the end.
Under review
Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.
Congratulations to our community stars!
Expanding mentorship, skilling, and AI innovation
These are the community rock stars!
Stay up to date on forum activity by subscribing.
WarrenBelz 358 Most Valuable Professional
11manish 214 Super User 2026 Season 2
Mohsin Ali 185