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 / Power Apps Toggle - Pa...
Power Apps
Answered

Power Apps Toggle - Patch Issues for Updating Records

(0) ShareShare
ReportReport
Posted on by 16

Hello! I am currently developing my first Power App which will be used to record attendance for Instructor Led Training events. I have about 95% of the Canvas working properly, with one exception. I'm having a challenge with getting the Toggle to Patch records correctly. 

 

Basically, the Canvas is a list of employees (redacted for privacy) and next to their name is a Check In box. When they select Check In, it will mark them as "Here" and also capture the Date/Time Stamp for record keeping purposes. That is all functioning 100% with no issues. Everything feeds back to the source file and is updated properly. 

 

I have a Toggle at the top of the page that is meant to be used by the Instructor to mark when the training is completed. My thought was the Toggle could be used to capture the end time and update all records where the employee is marked as "Here". However, I cannot get it to function the way I am imagining it. 

 

I know I am missing something in the Patch statement, but don't know what. Below is a screenshot of the Canvas. Hoping someone has come across this before and has a potential solution. Or if there is a better way (not using a Toggle) I am open to that, as well. The Toggle is just a clean look, so hoping we can make it work. Thanks all! 

 

Note - behind the Blue sections is most of the data, which has been redacted for privacy, but it is much more robust than what you're seeing. 

 

PowerAppsCheckIn.png

Categories:
I have the same question (0)
  • Verified answer
    BCBuizer Profile Picture
    22,833 Super User 2026 Season 1 on at

    Hi @smitty1 

     

    The UpdateIf function is perfect for your scenario although you will also need to have a column in your data source that records the training session:

     

    UpdateIf(
     DataSourceName,
     HereColumnName = "Here" &&
     TrainingSessionColumnName = varTrainingSession,
     {EndTimeColumnName: Now()}
    )

     

    In the above you need to replace anything that has "Name" in it with the actual name of the data source / column. For the example I used a variable (varTrainingSession) that should have a unique identifier for the training session, but this can be a reference as well.

  • smitty1 Profile Picture
    16 on at

    @BCBuizer Thanks, so much! I will give this a try, right now! Just to confirm, is this going to go in the OnSelect action box or? 

  • BCBuizer Profile Picture
    22,833 Super User 2026 Season 1 on at

    Hi @smitty1 ,

     

    This can indeed be used in the OnSelect property of the toggle.

     

    Be careful though, because it will run every time somebody selects it. You may want to disable the toggle after it has been pressed once.

  • smitty1 Profile Picture
    16 on at

    @BCBuizer It is now functioning 100% properly. Thanks so much for the assist! 

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 335 Most Valuable Professional

#2
11manish Profile Picture

11manish 166

#3
sannavajjala87 Profile Picture

sannavajjala87 71 Super User 2026 Season 1

Last 30 days Overall leaderboard