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

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Make dynamic size of g...
Power Apps
Unanswered

Make dynamic size of gallery

(0) ShareShare
ReportReport
Posted on by

Hi, hope you are doing great!

I am working on a PowerApps. I am using a ‘Gallery’ to capture information filled by user.

+ Button at right top, makes gallery visible and can further add more rows by clicking on + button.

 
 
 

Dynamic gallery 1.png

 

Formula on 'On Select' property of + button -

Collect( 
NewCollection, 
   { 
      CItemSerialNumber: Text(Last(NewCollection).CItemSerialNumber + 1),
      drpActionItem: "", 
      txtOtherActionItem: "", 
      txtDescription: "", 
      drpStatus: "",
      txtNotesActionTaken:"",
      txtClosureOwnerName: "",
      dteClosureDate: "" 
   } 
)

 

Requirement : Gallery size is static. After clicking on + button, gallery is visible at bottom. If, user has to add more rows that gallery looks crowded with lot of info.

Need to make gallery size dynamic. So, once user clicks than gallery should appear on top of main screen.

 

Dynamic gallery 2.png

 

Appreciate your help to achieve dynamic gallery size.

@WarrenBelz @RandyHayes @AJ_Z 

 

Categories:
I have the same question (0)
  • Verified answer
    v-jefferni Profile Picture
    on at

    Hi @AJ_vizMan ,

     

    You can use context variables to change the Gallery position. So:

    1. OnSelect of the add button:

    UpdateContext({GalleryY: A Y axis value for the Gallery you want to put, GalleryH: A height value for the high Gallery})

     

    2. OnSelect of the Cancel and Save button, add the following formula after your original formula:

    UpdateContext({GalleryY: The Y axis value of the Gallery's current position, GalleryH: The height value of the short Gallery})

     

    3. Set Y axis of the Gallery to GalleryY

     

    4. Set Height of the Gallery to GalleryH

     

    Hope this helps.

     

    Best regards,

    Community Support Team _ Jeffer Ni
    If this post helps, then please consider Accept it as the solution to help the other members find it.

  • AJ_vizMan Profile Picture
    on at

    This is easy and simple solution. Thank you @v-jefferni for help.

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

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 793 Most Valuable Professional

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 333 Super User 2025 Season 2

#3
Power Platform 1919 Profile Picture

Power Platform 1919 268

Last 30 days Overall leaderboard