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 Apps
Unanswered

Gallery validation

(0) ShareShare
ReportReport
Posted on by 133

When I hit next Button I want to validate the gallery. The error masg need to show only below the text inputs in the gallery. 

 

But here i get the error masg even there is a value.

 

Here is a  Screen shot

 

jufguu_0-1691564154926.png

 

Categories:
I have the same question (0)
  • earribasb Profile Picture
    74 on at

    Hello! Could you explain a little bit more your problem? How do you validate the gallery? Can you paste the piece of code?

  • LaurensM Profile Picture
    12,516 Moderator on at

    Hi @jufguu,

     

    How are you currently showing the error messages? You may have to add additional logic that checks whether the control within that row is blank in addition to your current condition:

     

    //e.g. the Visible property of the error messages
    IsBlank(Dropdown1.Selected) && <Your current logic>

     

    If this solves your question, would you be so kind as to accept it as a solution & give it a thumbs up.

    Thanks!

  • jufguu Profile Picture
    133 on at

    This is the code I use in the next button

     

    If(IsBlank(ComboBoxCostCenter.SelectedItems),UpdateContext({locErrorCostCenterGallery:true}));
    If(IsBlank(ComboBoxNatureOfGL.SelectedItems),UpdateContext({locErrorNatureOfGLGallery:true}));
    If(IsBlank(ComboBoxGLAccount.SelectedItems),UpdateContext({locErrorGLGallery:true}));
    If(IsBlank(txtAmount1_1.Text),UpdateContext({locErrorAmount1Gallery:true}));

     

    If(!IsBlank(ComboBoxCostCenter.SelectedItems),UpdateContext({locErrorCostCenterGallery:false}));
    If(!IsBlank(ComboBoxNatureOfGL.SelectedItems),UpdateContext({locErrorNatureOfGLGallery:false}));
    If(!IsBlank(ComboBoxGLAccount.SelectedItems),UpdateContext({locErrorGLGallery:false}));
    If(!IsBlank(txtAmount1_1.Text),UpdateContext({locErrorAmount1Gallery:false}));

     

     

  • earribasb Profile Picture
    74 on at

    The problem that you have, if i understood your logic, is that you are validating the controls from the next button, which is outside the galley, so you are pointing to a context variable which is validating any control and it appears many times...

    I suggest you to setup your logic directly in your label by pointing it to the related comboboxN.slecteditems. It will validate against the control of the current record

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

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Congratulations to the April Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
Vish WR Profile Picture

Vish WR 839

#2
Valantis Profile Picture

Valantis 533

#3
Haque Profile Picture

Haque 412

Last 30 days Overall leaderboard