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 / Validate that Gallery ...
Power Apps
Answered

Validate that Gallery has items before submitting

(0) ShareShare
ReportReport
Posted on by 901

Already got the required fields validation working for 

  •  Requestor Name
  • Address
  •  Facility Name

 

What is the best approach to also validate that gallery must has an item added. Before the user could submit.

 

If(!Form2.Valid,SubmitForm(Form2),ForAll(Gallery1.AllItems,Patch('Pitney Bowes',Defaults('Pitney Bowes'),Form2.Updates,{Category:TextInput2.Text},{SubCategory:TextInput3.Text},{ProductName:TextInput4.Text},{Quantity:TextInput4_1.Text},{Price:Value(TextInput4_2.Text)}));Office365Outlook.SendEmail("ofuentes@convivasolutions.com","New Order","Pitney Bowes"; HtmlText1.HtmlText, { IsHtml: true });Navigate('Finish Screen'))

 

Hope l explain clearly 

Gallery.PNG

Categories:
  • Verified answer
    Pstork1 Profile Picture
    69,665 Most Valuable Professional on at

    Use an IF() to check whether CountRows(Gallery.AllItems) > 0.  

  • oappdev Profile Picture
    901 on at

    Winner winner chicken dinner! Thanks a million @Pstork1 

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

Leaderboard > Power Apps

#1
11manish Profile Picture

11manish 352 Super User 2026 Season 2

#2
M Bilal Khan Profile Picture

M Bilal Khan 323

#3
Mohsin Ali Profile Picture

Mohsin Ali 226

Last 30 days Overall leaderboard