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 / Modern Control in Powe...
Power Apps
Answered

Modern Control in Power-Apps

(0) ShareShare
ReportReport
Posted on by 220

I’m working with a modern form control in Power Apps to update training records. There is an existing record where all fields, including the Training Date, are already populated.

When the form is in View mode, the Training Date control (DataCardValue_TrainingDate) correctly displays the stored date.

However, I don’t want users to modify this field, so I’ve set:

DataCardValue_TrainDate.DisplayMode = DisplayMode.View

Now, when I switch the form to Edit mode, the Training Date field becomes blank, even though the data exists and the control is still set to View mode.

Requirement:

I need the Training Date to be visible (read-only) in both View mode and Edit mode, without allowing users to edit it.

Issue:

Why does the date disappear in Edit mode, and how can I ensure it consistently displays the existing value regardless of the form mode?

Categories:
I have the same question (0)
  • Suggested answer
    MS.Ragavendar Profile Picture
    7,431 Super User 2026 Season 1 on at
     
    I too experience this issue while designing with Modern forms based on the experience which i had 
     
    In EditForm mode, the control: Stops binding to ThisItem properly and it Doesn’t auto-populate from the record this causing the Result → Blank value displayed
     
    Unlike Classic controls, Modern controls don’t automatically retain the value when forced into View mode inside an Edit form.
     
    Instead of relying on default binding, force it like this:
     
    If(
        !IsBlank(Parent.Default),
        Parent.Default,
        ThisItem.ColumnName
    )
     
    (Or) Coalesce(Parent.Default, ThisItem.ColumnName)
     
    ✅If this helped, please Accept as Solution to help others ❤️ A Like is appreciated 🏷️ Tag @MS.Ragavendar for follow-ups.
  • Suggested answer
    Valantis Profile Picture
    6,735 on at
     
    Modern controls in edit forms don't retain their bound value when DisplayMode is forced to View on the control itself, because the form's edit context resets the control's binding.

    The fix, set the Default property of the DataCardValue to explicitly reference the record:
    Coalesce(Parent.Default, ThisItem.TrainingDate)

    This ensures the date always shows the stored value regardless of the form mode.
    For the read-only requirement specifically, there's a cleaner approach that avoids the blank issue entirely: instead of setting DisplayMode.View on the date picker control, lock the entire data card instead. Set the data card's DisplayMode property to:
    Parent.DisplayMode = FormMode.Edit : DisplayMode.View : Parent.DisplayMode
    This makes the card read-only in edit mode while still showing the value correctly, without fighting the modern control's binding behavior.
     

     

    Best regards,

    Valantis

     

    ✅ If this helped solve your issue, please Accept as Solution so others can find it quickly.

    ❤️ If it didn’t fully solve it but was still useful, please click “Yes” on “Was this reply helpful?” or leave a Like :).

    🏷️ For follow-ups  @Valantis.

    📝 https://valantisond365.com/

    💼 LinkedIn

    ▶️ YouTube

  • Suggested answer
    11manish Profile Picture
    3,333 on at
    For a field that is always read-only, the preferred solution is to display the date in a Label or use a disabled Date Picker instead of setting the Modern Date Picker to DisplayMode.View. If the issue persists only with the Modern control and all properties are configured correctly, it is likely a current limitation of the Modern Controls framework.
     
    If you need a more specific solution, please share:
    • Your data source (SharePoint, Dataverse, SQL, etc.).
    • Whether you're using a Modern Form or a Classic Edit Form.
    • The formulas for the DataCard Default, DataCard Update, and the Modern Date Picker's Value/Default property. This will help determine whether the issue is due to configuration or a known control limitation.
  • Power Platform Guy Profile Picture
    220 on at
    @MS.Ragavendar thanks it worked.
     
    thanks to @Valantis /@11manish for the inputs

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 Launch!

Jump in, show your community spirit, and win prizes!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Congratulations to the May Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
Valantis Profile Picture

Valantis 424

#2
WarrenBelz Profile Picture

WarrenBelz 355 Most Valuable Professional

#3
11manish Profile Picture

11manish 290

Last 30 days Overall leaderboard