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 / Canvas App to show sta...
Power Apps
Answered

Canvas App to show status of machines using toggle buttons

(1) ShareShare
ReportReport
Posted on by 15

I have created a canvas app with a custom UI that has toggle buttons and labels for each toggle, displaying username and datetime when a user selects the toggle. The toggle button patches this information to a MS List.
Whenever I play the app it shows me the default view where all the toggle buttons are OFF,

for instance I have 5 machines with status ON or OFF, by default the status is OFF, when I select a toggle for machine 1 it gets turned On and the status is updated in MS list as ON, but when I close and play the app again the toggle is OFF for machine 1.
I want the app to collect the information from MS List and then show the information as and when it is opened or played.

Any leads how to achieve this.

 

Categories:
I have the same question (0)
  • Bilakanti Profile Picture
    1,226 on at

    @pujaclb You can set the default property of the toggle to the MSlist column value.

    Ex: MSList.<columnname>

  • Verified answer
    iAm_ManCat Profile Picture
    18,256 Most Valuable Professional on at

    Let's assume you have a list, and you are patching to it (as you've said), and I assume you will have columns for the MachineName, MachineStatus and a Username column where you store the user's email address (as display name is not a unique identifier)

     

    Make the Default of each toggle the following, while changing the values for each to match the machine each toggle is for:

    LookUp('DataSource Name', MachineName = "Machine 1").MachineStatus

     

    The above does assume that you have one list for all machines, rather than a row for each user. If you need to also filter by user then you will need something like this (assuming you are currently storing User().Email when you patch):

    LookUp('DataSource Name', MachineName = "Machine 1", UsernameColumn = User().Email ).MachineStatus

     

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!

Congratulations to the March Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
11manish Profile Picture

11manish 541

#2
WarrenBelz Profile Picture

WarrenBelz 434 Most Valuable Professional

#3
Valantis Profile Picture

Valantis 289

Last 30 days Overall leaderboard