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 / PowerApps Form Height
Power Apps
Suggested Answer

PowerApps Form Height

(1) ShareShare
ReportReport
Posted on by 32
I hava added a form that has datacards which are visible dynamically based on the selection category.  I am not able to set the form height based on the datacards that are visible. is there a way to set the height so that scroll bar is not visible?
Categories:
I have the same question (0)
  • Suggested answer
    kasraouiah Profile Picture
    305 on at
    Hello, 
    i think that your form exist within a container, within container you can mange vertical scrollbar visibility throught LayoutOverflowY 
  • WarrenBelz Profile Picture
    155,268 Most Valuable Professional on at
    If you set the Height of the non-visible Data Cards to zero (when they are not visible)
    If(
       Self.Visible,
       0,
       TheNormalHeight
    )
    and assuming that when a card is not visible, the entire row is not visible, then you can add up the heights of the tallest data card in each row for the Height of the Form.
    DataCard1.Height + DataCard4.Height + DataCard8.Height + . . . .


    ​​​​​​​Please click Does this answer your question if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it a Like.
    MVP (Business Applications)    Visit my blog Practical Power Apps    Buy me a coffee
  • WarrenBelz Profile Picture
    155,268 Most Valuable Professional on at
     
    A quick follow-up to see if you received the answer you were looking for or if you need further assistance.

    Please click Does this answer your question if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it a Like.
    MVP (Business Applications)    Visit my blog Practical Power Apps    LinkedIn   
  • CU08111717-0 Profile Picture
    32 on at
    Thank you for your responses, It is working for a single column form. However, it is still displaying scrollbar for 2 columns form. If I set it based on last datacard height and Y it sets the form height sometimes but not consistently
     
  • WarrenBelz Profile Picture
    155,268 Most Valuable Professional on at
    If you want to dynamically hide Data Cards to alter the Form Height, you need to hide (or not) the entire row - Power Apps will not automatically "wrap" cards to the next line if there is space. Is this your issue or is it something else ?
     
  • CU08111717-0 Profile Picture
    32 on at
    I have a vertical container, within the container I am using multiple dynamic forms where datacards are visible on condition. I don't want to display scroll bar on each form, therefore i am using the container scroll bar. but when screen size changes or datacard visible changes, the heights are not setting correctly in those forms and multiple scrollbars appear. 
    I am sharing a screen shot here, I am setting form heights with last datacard height , also tried adding all datacards height but still it is very inconsistent. 
     
     
  • Suggested answer
    TechFreak Profile Picture
    149 on at

    Hi,

    Yeah, this is a pretty common situation when you’re showing/hiding DataCards dynamically in a form in Power Apps.

    What’s happening is the Form control doesn’t automatically resize based on which DataCards are visible. It keeps its original height, so even if some cards are hidden, you still get empty space or a scrollbar.

    There isn’t a built-in “auto-height” for forms, but you can handle it by calculating the height based on the visible DataCards.

    If your form layout is vertical (one card per row), you can set the Height of the form like this:

    Sum(
        Filter(
            Form1.AllItems,
            Visible
        ),
        Height
    )
     

    This works because:


    • Form1.AllItems gives all DataCards

    • Filter(..., Visible) keeps only the visible ones

    • Sum(..., Height) adds up their heights
     

    If you have some spacing/padding between cards, you can add a small buffer:

    Sum(
        Filter(Form1.AllItems, Visible),
        Height
    ) + 20
     

    If your form has multiple columns, then it gets a bit trickier because items are arranged in rows. In that case, you may need to:


    • Keep the form single-column for dynamic layouts

    • Or switch to a custom layout using containers instead of a form
     

    So basically, Power Apps won’t auto-adjust the form height for you, but you can calculate it based on visible DataCards to remove the scrollbar.

     

    Best regards,
    Satyam Pandey

     

    ✅ If this helped solve your issue, please mark it as Accepted Solution so others can find it quickly.

    ❤️ If it was helpful, please click Yes on “Was this reply helpful?” or give it a Like.

    🏷️ For follow-ups, feel free to tag @TechFreak

    💼 LinkedIn

    ▶️ YouTube

  • Suggested answer
    oyepanky Profile Picture
    527 on at
    Hi @CU08111717-0,

    Dynamic Form Height (No Scrollbar)
    PowerApps Form doesn’t auto-resize based on visible DataCards, so you need to calculate height manually.

     Set Form Height
    Sum(
        Filter(FormName.AllItems, Visible = true),
        Height
    )
    Better (Add spacing)
    Sum(
        Filter(FormName.AllItems, Visible = true),
        Height
    ) + 20
     
    • Works only if AutoHeight = true on DataCards
    • Hidden cards (Visible = false) won’t be counted
    • Disable Form scrollbar: Set FormName.Scrollable = false

    Result > 
    ✔ Form height adjusts dynamically
    ✔ No scrollbar
    ✔ Clean UI based on visible fields

    Best Regards,
    Pankaj Jangid (OyePanky)
    Power Platform Developer
    Website: https://dialforit.com
    YouTube: https://www.youtube.com/@Oyepanky
     

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 March Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
Vish WR Profile Picture

Vish WR 936

#2
11manish Profile Picture

11manish 628

#3
Valantis Profile Picture

Valantis 604

Last 30 days Overall leaderboard