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 / undefinedCheckox.value...
Power Apps
Answered

undefinedCheckox.value=true, .value is being underlined in red.

(0) ShareShare
ReportReport
Posted on by 309

I am trying to disable a button if a checkbox is unchecked. But for some reason Checkox.value=true, .value is being underlined in red. I tried to reproduce, it works the first time and if I edit the formula it starts undying .value. 

 

value.jpg

 

The other issue I have is that after navigating to another screen it does not clear the check box i tried on visible property of the screen but it is still check when i navigate back to it. 

UpdateContext({Acknowledgment_2:false})

Thanks in advance, 

Categories:
I have the same question (0)
  • Verified answer
    WarrenBelz Profile Picture
    156,117 Most Valuable Professional on at

    @Yemata ,

    For the first one is Acknowledgement_2 the name of the checkbox? Try

    If(
     Acknowledgement_2.Value=1,
     DisplayMode.Edit,
     DisplayMode.Disabled
    )

    For the second, UpdateContext() sets a Variable, not a control. You just need to Reset it 

    Reset(Acknowledgement_2)

     

    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.

  • DaynaBee Profile Picture
    309 on at

    @WarrenBelz Thank you. I tried both for some reason it is not working.  ☹️Reset.jpgackg.jpg

  • WarrenBelz Profile Picture
    156,117 Most Valuable Professional on at

    @Yemata ,

    What is the name of your checkbox (not the field it contains) - you need to use that.

     

    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.

  • DaynaBee Profile Picture
    309 on at

    I am using the PowerApps Checkbox control, it is not a field from a list. And its name is "Acknowledgment_2". ckbox.jpg

  • WarrenBelz Profile Picture
    156,117 Most Valuable Professional on at

    @Yemata ,

    Something else wrong here - a checkbox has only two possible values (true or false) that at times need to be referred to as 1 or 0.  Also .Value is the correct reference to it. Try replacing it with another checkbox and see if that works.

     

    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.

     

     

  • DaynaBee Profile Picture
    309 on at

    Exactly, I have tried with new checkbox and new button multiple times. works the first time and it suddenly starts underlining it with red. 😟

  • DaynaBee Profile Picture
    309 on at

    @RandyHayes @Pstork1 @v-j  @Anonymous  Any idea on how to resolve this? 

  • Pstork1 Profile Picture
    69,601 Most Valuable Professional on at

    Since Power Apps is declarative it tends to be a problem to try to set properties on controls based on other controls.  Instead do the following

    Reset the checkbox in the screen OnVisible.

     

    reset(Acknowledgement_2)​;set(disableButton,false)

    Use the OnCheck and OnUncheck to set a variable to the status of the checkbox

     

    Set(disableButton,true)
    Set(disableButton,false)​​

     

    Set the displayMode of the button based on disableButton

    If(disableButton,DisplayMode.Edit,DisplayMode.Disabled)​​



  • DaynaBee Profile Picture
    309 on at

    @Pstork1 Thank you. I tried it your way but it is still not working.

     onVisible.jpg

    unck.jpg

    display.jpg

    ck.jpg

     

    Only OnCheck is not throwing an error. 

  • Pstork1 Profile Picture
    69,601 Most Valuable Professional on at

    I agree with @WarrenBelz .  I think you need to delete the toggle control and re-add it to the screen.  The error you are getting is suggesting the Acknowledgement_2 control doesn't exist.

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 June Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 326 Most Valuable Professional

#2
11manish Profile Picture

11manish 168

#3
sannavajjala87 Profile Picture

sannavajjala87 75 Super User 2026 Season 1

Last 30 days Overall leaderboard