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 / Make some Text Input f...
Power Apps
Answered

Make some Text Input fields read-only in Edit Forms

(0) ShareShare
ReportReport
Posted on by 38

Hello All

 

I use an Edit Form with a SharePoint list as data source. Users fill in the form completely. Once done they click on a button. The top 3 text inputs are saved in a variable and have the default property set to their variables. 

Now I need these top 3 text inputs set to read-only so they can only fill in the other fields.

When trying this out I can still fill in the top 3 text-inputs. Please help.

Categories:
I have the same question (0)
  • Verified answer
    mdevaney Profile Picture
    29,991 Moderator on at

    @Flowbginner
    Put this code in the OnVisible property of your screen

    Set(readOnlyFields,false);


    Next, put this code in your Add A Service button

    Set(readOnlyFields,true);



    Finally, put this code in the DisplayMode property of each of your 3 DataCard value fields

    If(readOnlyFields=true,View,Edit);



    —-
    Please Accept as Solution if this post answered your question so others may find it more quickly. If you found this post helpful consider giving it a Thumbs Up.

  • Flowbginner Profile Picture
    38 on at

    Thank you so much!!!! It works!Smiley Very Happy

  • Flowbginner Profile Picture
    38 on at

    @mdevaney  do you know how I can merge the inputs from an edit form togther with Text Inputs outside the edit form so it only writes 1 single item in a SharePoint list?

  • Share-and-Flow Profile Picture
    32 on at

    The same solution worked for 2 days, and then on day 3 it has stopped working. Nothing was changed.
    But now, even the Status="Approved" forms have editable fields.
    OnVisible property of screen:
    If(StatusValue.Selected.Value= "Approved" Or StatusValue.Selected.Value= "Rejected", Set(readOnlyFields,true), Set(readOnlyFields,false));

    DataCard value fields:
    If(readOnlyFields=true,View,Edit);

  • WarrenBelz Profile Picture
    154,492 Most Valuable Professional on at

    Hi @Share-and-Flow ,
    The code you show should work, but as a more reliable alternative, you could drop the Variable and put this on the DisplayMode of the controls

    If(
     StatusValue.Selected.Value= "Approved" ||
     StatusValue.Selected.Value= "Rejected",
     DisplayMode.View,
     DisplayMode.Edit
    )

     

    Please click Accept as solution 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 Thumbs Up.

  • Share-and-Flow Profile Picture
    32 on at

    Thank You @WarrenBelz 

    I was going to try your solution, but today my setting started to work again.

    This makes it feel so unreliable, I am confused , but its working now.

  • WarrenBelz Profile Picture
    154,492 Most Valuable Professional on at

    OK @Share-and-Flow ,

    Please let me know - the reliable solutions are sometimes the simplest.

  • ArtieLeech Profile Picture
    42 on at

    We wanted a similar thing as the OP - a Text Input (that we made multi-line) which we wanted to be read-only.

     

    Our solution was to change the TextInput's Display mode to Disabled:

     

    ArtieLeech_0-1642589682351.png

     

     

     

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!

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 549 Most Valuable Professional

#2
Kalathiya Profile Picture

Kalathiya 225 Super User 2026 Season 1

#3
Haque Profile Picture

Haque 224

Last 30 days Overall leaderboard