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 / Autoheight Bug on Form...
Power Apps
Unanswered

Autoheight Bug on Forms within Scrolling Canvas

(0) ShareShare
ReportReport
Posted on by 21

I am experiencing a bug similar to what was dicussed here: https://powerusers.microsoft.com/t5/Building-PowerApps-Formerly/Potential-Bugs-AutoHeight/m-p/18358#M7999

 

In the case of an infinite scrolling canvas where I have added several data cards and one of those data cards contains a custom form where at least one of the data cards on that form contains a label control with autoheight turned on.  Anytime the content within that autoheight control changes AFTER the screen loads, resulting in the height of that label changing, the height of the form that contains it will not update (i.e. if the autoheight control gets bigger, I end up having to scroll on the form within the data card on the canvas; or if the autoheight control gets shorter, then I end up with extra whitespace at the bottom of the form).  Doing something that results in the form "rerendering" such as clicking a button that cycles the form from Not Visible then back to Visible, or leaving the screen and returning to it, then causes the form height to properly update and be the proper height.

 

As a partial workaround I can use a variable tied to the onchange event of a combobox control that affects what is displayed in the label (it didn't work when I tried to just use the OnChange event of the autoheight Label itself) and the visible property of the form control like this:

Screen1.OnVisible = Set(ResetForm, false); Set(ResetForm, true)
ComboBox1.OnChange = Set(ResetForm, false);Set(ResetForm, true)

Form1.Visible = ResetForm

 

But this only works when that control is changed AFTER the screen/form initially loads.  If I were to view a record where that label contains enough text to make it 3 lines tall, then return to a gallery screen and select a record where the label only needs to be 1 line tall, the label's autoheight doesn't kick in until after the screen has loaded (and the OnVisible property of the screen has already run), so I end up with a Form with a height that is too short to view it without scrolling (at least until I change something on it and my previous workaround causes the visibility of it to cycle).  I realize I could use a timer control that does this a second or two after the screen loads, but that is going to look glitchy to the user.  Any better workarounds?  Any plans to get this bug fixed?

Categories:
I have the same question (0)
  • v-xida-msft Profile Picture
    on at

    Hi @csteig1230 ,

    Do you add a Scrollable screen within your app?

     

    Firstly, I agree with the alternative solution you mentioned above. Based on the issue that you mentioned, it seems an known issue with the AutoHight property of the Label control. As an alternative solution, please consider take a try with the following workaround:

    Set the OnHidden property of the Detail screen (Screen1) to following:

    Set(ResetForm, false);Set(ResetForm, true)

    When you leave tlhe Detail screen (contains the Form), reset the form.

     

    Also please consider take a try to turn off the "Improved app rendering (final validation)" option within Advanced settings of App settings of your app, then try above solution, check if the issue is solved.

     

    Best regards,

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 721 Most Valuable Professional

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 320 Super User 2025 Season 2

#3
Power Platform 1919 Profile Picture

Power Platform 1919 268

Last 30 days Overall leaderboard