My canvas app has gallery with current user filter. As long as there are records for the logged in user, there are no complaints. But when a user login for the 1st time, obviously there wont be any of his items in the gallery. For this 1st time user when there are no items in the gallery, i dont want to show him a empty gallery. I would like to display a message on screen "There are no submitted forms currently for you. Please submit a form by clicking on '+' icon above". How do I have this message available for new users and gallery items for old users on the same screen.
@RameshMukka
You can hide the Gallery by changing its Visible property to this code
!IsEmpty(Gallery1.AllItems)
Then you can make a label with a custom message that appears when there are no records by putting this code in the Visible property.
IsEmpty(Gallery1.AllItems)
---Please click "Accept as Solution" if my post answered your question so that others may find it more quickly. If you found this post helpful consider giving it a "Thumbs Up."
Do I have to hide other elements on the page as well? Like on my screen below, along with my gallery I have a rectangle, a label, an icon etc.
@RameshMukka No, once the gallery is hidden everything else inside it will disappear as well. You only have to write the code in one place: the gallery's Visible property and it will take care of everything.
@mdevaney But my other controls are not shown within the gallery. They are outside gallery. Does gallery allow to have controls inside it?
@RameshMukka I assumed you were talking about controls inside the gallery.
Yes, you must hide each one using this code in the Visible property
@mdevaney I have a small problem here. There isnt any problem for the new user now. But for a user when there are gallery items the custom message pops up for a second or 2 before the custom message goes hidden and gallery is shown? How can I avoid this custom message to be shown for for a second or 2 when the gallery is not empty. Thanks a lot in advance.
Thanks,
Ramesh
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.
In our never-ending quest to improve we are simplifying the forum hierarchy…
We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…
These are the community rock stars!
Stay up to date on forum activity by subscribing.
WarrenBelz 757 Most Valuable Professional
Michael E. Gernaey 322 Super User 2025 Season 2
MS.Ragavendar 209 Super User 2025 Season 2