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 / Auto Height for Text I...
Power Apps
Unanswered

Auto Height for Text Input on Data Card

(0) ShareShare
ReportReport
Posted on by 20

I have a Canvas screen with a Datacard that contains 2 forms and each of the form has an additional data card.  The final data card on the forms each have an text input field that needs to have its height automatically resize based on the text the user has/and is inputting.  The 2 forms are not resizing automatically.  When running the application the forms display a scrollbar which is not desired.

 

I can get the text input to resize based on the text the user has/is inputting based on this workaround:  https://powerusers.microsoft.com/t5/Videos/TextInput-Configuring-Auto-Height/td-p/101160

 

When making modifications to the application (in development mode) I can manually enter a formulas for the height of the form and datacards and the scroll bar disappears.  However, if I run the application, the scroll bar re-appears even though the formula worked when editing the application.

 

Has anyone encountered anything like this before or have any suggestions that would work when running the application as an end-user?

 

How the form looks when editing the form:

EditView.jpg

This is the formula for the height of the DataCards that contain the text input is:

 

Max(150, txt_Comments.Height + dc_CommentTitle.Height + 20)

 

 

This is the formula for the height of the forms is:   

 

Max(150, dc_Comments.Height + 20)

 

 

When running the application in Preview or Live this is how the form looks (the scrollbar is not desired on the forms - highlighted in yellow):

ViewIssue.jpg

 

Categories:
  • v-siky-msft Profile Picture
    Microsoft Employee on at

    @kemppaik 

    I figure out the issue is from Max function in Height property of textinput .

    If you don't set the Max function, the issue won't appear. However, the Height will be zero if nothing is entered.

    Snipaste_2020-01-22_15-26-01.png

    As an alternative workaround, If textinput is empty, set Label text to a line of space, then the textinput won't be zero height.

    Please set the Text of Label:

    If(IsBlank(TextInput1.Text)," ",TextInput1.Text)

    Sik

  • Karen K Profile Picture
    20 on at

    Thanks for the reply.  I've tried to do this but I'm still not getting the field to display the proper height when the application is published.

     

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

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Leaderboard > Power Apps

#1
11manish Profile Picture

11manish 350 Super User 2026 Season 2

#2
M Bilal Khan Profile Picture

M Bilal Khan 318

#3
Mohsin Ali Profile Picture

Mohsin Ali 220

Last 30 days Overall leaderboard