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 / Enable Save Button Ico...
Power Apps
Answered

Enable Save Button Icon on Datepicker date change

(0) ShareShare
ReportReport
Posted on by Microsoft Employee

Hi ,
I have datepicker control in my gallery , if i change date then my save button icon should enable in edit mode.

i initially did set displaymode.view for save button icon then on datepicker on change if trying to change save button displany mode back to edit.  if(ThisItem.ID,DisplayMode.Edit,View) -- not changing save button display mode.

please advise.

Categories:
I have the same question (0)
  • Verified answer
    FabianAckeret Profile Picture
    969 on at

    Hi @Anonymous 

     

    You have the right approach. However, in your if statement you are just asking if ThisItem.ID is true or false. In other words, if ThisItem.ID isn't empty, it is true. And since ThisItem.ID is probably always true, it will just keep in the DisplayMode.Edit.

     

    So, if you want to change the DisplayMode of your save icon based on your datepicker, you could do as follows:

    • On the OnChange property of your datepicker, set it to UpdateContext({lclDateChanged: true})
    • On the DisplayMode property of your Save Icon, change it to 

     

    If(lclDateChanged,DisplayMode.Edit,DisplayMode.View)​

     

    • Once submitting the form, you should reset the lclDateChanged variable again. To do that, you could add the following line to the OnSelect property of your Save button

     

    UpdateContext({lclDateChanged:false});​

     

    I hope this helps.


    Please click Accept as Solution if my post answered your question. Like my answer? Consider giving it a Thumbs Up. Others seeking the same answers will be happy you did.

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    Thanks , Its perfectly working fine now 😊

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