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 / How to make a cell edi...
Power Apps
Answered

How to make a cell editable only if in a new form

(0) ShareShare
ReportReport
Posted on by 54

I have a form where once it has been saved if they go back to edit that form anything that has data in cannot be editable but anything blank they can edit.

 

I have tried the below is the display mode of the field that they type in but getting an error:

 

If(
IsBlank(ThisItem.Datcardvalue65.text),
DisplayMode.Edit,
DisplayMode.View
)

Categories:
I have the same question (0)
  • mmollet Profile Picture
    3,187 on at

    Try: If(IsBlank(Self.Text), DisplayMode.Edit, DispalyMode.View)

     

    This would be on the actual input where the text goes. 

  • jdrm1 Profile Picture
    54 on at

    that works but then when you typing in the box it suddenly changes it to view before you have finished mid typing

  • jdrm1 Profile Picture
    54 on at

    I believe I need it to look at the data source to check if it can see anything that way when typing it should not suddenly change before they click save

  • NandiniBhagya20 Profile Picture
    4,667 Super User 2024 Season 1 on at

    Hi @jdrm1 ,
    If you are using a form control, try below - 
    If(
    IsBlank(Parent.Default),
    DisplayMode.Edit,
    DisplayMode.View
    )
    OR

    If(
    FormName.Mode=FormMode.New,
    DisplayMode.Edit,
    DisplayMode.View
    )
    OR
    If(
    IsBlank(LookUp(DataSourceName, ID=<ID of the item>)),
    DisplayMode.Edit,
    DisplayMode.View
    )

  • jdrm1 Profile Picture
    54 on at

    What do you mean by ID of the item? how do I check that.

    Also just so you know you should not use a capital R in Or

  • Verified answer
    NandiniBhagya20 Profile Picture
    4,667 Super User 2024 Season 1 on at

    Hi @jdrm1 ,
    Apologies for the confusion. You can use any formula from the below three options (I would suggest to go with option 1) - 
    1. If(
    IsBlank(Parent.Default),
    DisplayMode.Edit,
    DisplayMode.View
    )

    2. If(
    FormName.Mode=FormMode.New,
    DisplayMode.Edit,
    DisplayMode.View
    )

    3. If(
    IsBlank(LookUp(DataSourceName, ID=<ID of the item>)),
    DisplayMode.Edit,
    DisplayMode.View
    )

     

    Answering to your query, ID is current item ID (it will only be there in edit and view form). ID gets created when you create a new item. It's kind of a unique identifier. 

  • jdrm1 Profile Picture
    54 on at

    Thank you that seems to work. I think I was making it more complicated than need to.

  • jdrm1 Profile Picture
    54 on at

    I know you got that working, but just realised if it is yes no slider option that changes it to text and then you can no longer use the slider. Any ideas?

  • NandiniBhagya20 Profile Picture
    4,667 Super User 2024 Season 1 on at

    HI @jdrm1 ,
    Do have a toggle control (yes/no) in your form which is responsible for visibility (hide/show) of "Datcardvalue65" control and you want to incorporate this control in the formula?

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

Congratulations to the July Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 329 Most Valuable Professional

#2
11manish Profile Picture

11manish 209 Super User 2026 Season 2

#3
Mohsin Ali Profile Picture

Mohsin Ali 179

Last 30 days Overall leaderboard