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 Pages / How to disable fields ...
Power Pages
Answered

How to disable fields once update button is clicked on Profile ?

(0) ShareShare
ReportReport
Posted on by 503

Hi all 

 

I am trying to disable these fields once the update button is clicked - 

tempsnip4343.png

I only want the user to update the form above once. 

 

I have tried adding some JS to the Localized content of the 'Profile' Web Page which is like this -

$('#ContentContainer_MainContent_MainContent_ContentBottom_SubmitButton').click(function(){
 $('#firstname').attr('disable');
});

 

Capture1234.JPG

 

So the button should be disabling the firstname text input once clicked but it doesnt work here? 

 

I have tested in jsfiddle.net and it works so I dont think the JS is incorrect. Please correct me if Im wrong. 

 

Any help here is appreciated. 

Categories:
I have the same question (0)
  • Verified answer
    oliver.rodrigues Profile Picture
    9,471 Most Valuable Professional on at

    Hi, just around your requirement, what happens if a user just refreshes the page? can they update the information again? that wouldn't make a lot of sense in my opinion

     

    I think what you are looking for is to disable the fields if they are populated, is that it? 

    if yes, your JS should happen on the on load and set the fields as read-only if they have values.

     

    I have an article to set fields read-only, see if it helps: http://oliverrodrigues365.com/2020/08/16/power-apps-portals-javascript-tip-02-set-attributes-read-only/

     

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 Pages

#1
rezarizvii Profile Picture

rezarizvii 55

#2
11manish Profile Picture

11manish 48

#3
Valantis Profile Picture

Valantis 46

Last 30 days Overall leaderboard