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

Community site session details

Session Id :
Power Apps - Building Power Apps
Answered

independent template size in gallery, nested gallery

(0) ShareShare
ReportReport
Posted on by 35

Hi, I can't make independend template size in main gallery which is depended on nested gallery side on button click.. Can't find solution fro hours 😞 

 

ShpxLbh_0-1669370965627.png


Main gallery templatesize is:

ShpxLbh_1-1669370994689.png


nested gallery is full with data on click:

ShpxLbh_3-1669371054538.png

and set height depend on button click..

ShpxLbh_2-1669371039648.png


But every template is the same, how to make individual row height?

Categories:
I have the same question (0)
  • Verified answer
    TN-12111106-0 Profile Picture
    35 on at
    Re: independent template size in gallery, nested gallery

    resolved. you have to use flexible gallery for that, You can't make it on standard gallery, even with some coding inside - it isn't work so good and smooth like on flexible gallery. 

  • sgtsnacks64 Profile Picture
    322 Super User 2024 Season 1 on at
    Re: independent template size in gallery, nested gallery

    Hey ShpxLbh,

     

    what about something like this using a Blank Flexible Height Gallery:

     

    Using a collection like this:

    ClearCollect(
     collection,
     Table(
     {
     Title: "1",
     Fill: Color.Blue,
     MakeBig: false
     },
     {
     Title: "The Quick Brown Fox Jumps Over The Lazy Dog",
     Fill: Color.Yellow,
     MakeBig: false
     },
     {
     Title: "Cheddar Cheese",
     Fill: Color.Red,
     MakeBig: false
     }
     )
    )

     

    We can use the MakeBig boolean value to control the height of a label in the gallery.

     

    sgtsnacks64_0-1669372990618.png

    Code in the Button (Although this could be anything OnSelect-y

     

    UpdateIf(collection,ThisItem.Title = ThisRecord.Title,{MakeBig: !MakeBig})


    The Label control then has its height defined by the variable:

     

    If(ThisItem.MakeBig,40,100)

     

    I've used a label as an example here, but it can also be blank:

     

    sgtsnacks64_1-1669373143336.png

     

    One caveat is you'll need to define the Height/Y co-ordinates of objects based on the state of the boolean value.

     

    A nested gallery, for example, could have its Height (Not it's template height) defined by the parent collection.

     

    Hope this helps you out 🙂

     

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

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Chiara Carbone – Community Spotlight

We are honored to recognize Chiara Carbone as our Community Spotlight for November…

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 652 Most Valuable Professional

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 410 Super User 2025 Season 2

#3
developerAJ Profile Picture

developerAJ 236

Last 30 days Overall leaderboard