web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / how to do data validat...
Power Apps
Answered

how to do data validation for all text input in a gallery.

(0) ShareShare
ReportReport
Posted on by

I want to do data validation for all text inputs field in a gallery. if any text input is blank the submit button should be disable.

data validation.PNG
Categories:
I have the same question (0)
  • Drrickryp Profile Picture
    Super User 2024 Season 1 on at

    @whykay1029 

    !IsBlank(Textinput1.Text)&&!IsBlank(Textinput2.Text)&& etc in the Visible property of the button.

  • whykay1029 Profile Picture
    on at

    @Drrickryp, i have tried what you solution, it only work the first item in gallery not all items in the gallery.

  • CNT Profile Picture
    10,921 Super User 2024 Season 1 on at

    @whykay1029 Use the following formula in the Display mode property of u'r Button, 

    If(CountIf(myGallery.AllItems, IsBlank(TextInput1) || IsBlank(TextInput2))>0, DisplayMode.Disabled, DisplayMode.Edit)

    Replace myGallery with u'r gallery name and TextInput1, TextInput2 etc., with the names of the TextInputs in u'r gallery.

  • Drrickryp Profile Picture
    Super User 2024 Season 1 on at

    @whykay1029 

    It appears that your save button is inside the gallery.  If that is the case, add ThisItem.IsSelected to the string.  It works fine in my screenshots:_1.jpg_2.jpg

  • whykay1029 Profile Picture
    on at

    @CNT, your solution work fine. I want to check with date field too.

  • whykay1029 Profile Picture
    on at

    The save button is not in the gallery. I want to check with date field too.

  • CNT Profile Picture
    10,921 Super User 2024 Season 1 on at

    @whykay1029  just add one more condition || IsBlank(DatePicker1) and it should work.

  • Verified answer
    whykay1029 Profile Picture
    on at

    @CNT, thanks for your help,it is working as you suggested.

  • CNT Profile Picture
    10,921 Super User 2024 Season 1 on at

    @whykay1029 Glad to help. 😊

     

    Please remember to give a 👍 and accept the solution so that it will be helpful for others.

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.

Helpful resources

Quick Links

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Congratulations to the July Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 345 Most Valuable Professional

#2
11manish Profile Picture

11manish 207 Super User 2026 Season 2

#3
Mohsin Ali Profile Picture

Mohsin Ali 177

Last 30 days Overall leaderboard