web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Apps
Unanswered

Help me!

(0) ShareShare
ReportReport
Posted on by 438

How I get two if value match? I do correctly?

 

If(LookUp('Maintenance Window', ID = 1).Status.Value = "Turn Off", 'DHS Homepage','DHS Maintenance Window')&If(LookUp('Maintenance Window', ID = 2).Status.Value = "Turn Off", 'DHS Homepage','DHS Maintenance Window (Summer Break)')

 

Categories:
I have the same question (0)
  • timl Profile Picture
    36,558 Super User 2025 Season 2 on at

    @dylandavis09 

    Nesting the If statements will take you closer to what you want to achieve.

    Note that with your current data structure, it's possible to "Turn On" both 'DHS Maintenance Window' and  'DHS Maintenance Window (Summer Break)'. In that case, which screen do you want to display?

    If(LookUp('Maintenance Window', ID = 1).Status.Value = "Turn Off"
     && LookUp('Maintenance Window', ID = 2).Status.Value = "Turn Off",
     'DHS Homepage', 
     If(LookUp('Maintenance Window', ID = 1).Status.Value = "Turn Off"
     && LookUp('Maintenance Window', ID = 2).Status.Value <> "Turn Off",
     'DHS Maintenance Window',
     'DHS Maintenance Window (Summer Break)'
     )
    ) 
    

     

  • charlessexton Profile Picture
    Super User 2024 Season 1 on at

    You'll want to have another bit of logic in there related to that then. Just another check in your If() function.

  • dylandavis09 Profile Picture
    438 on at

    Well, we need two different types of maintenance windows for our screens.

     

    The first Maintenance Window is for updates and security, and it is blocked during school hours due to testing or other reasons.

     

    The second Maintenance Window, specifically for Summer Break, is intended for students who have gone home for the summer break. This means students can't access it until they return next fall.

  • charlessexton Profile Picture
    Super User 2024 Season 1 on at

    How about this?

    If(
    	LookUp('Maintenance Window', ID = 1).Status.Value = "Turn Off" Or LookUp('Maintenance Window', ID = 2).Status.Value = "Turn Off",
    	'DHS Homepage',
    	'DHS Maintenance Window'
    )

     

    The confusing bit for me is why you have a 'DHS Maintenance Window' and a 'DHS Maintenance Window (Summer Break)'. Are both needed?

  • dylandavis09 Profile Picture
    438 on at

    Yes, I want to do that. I am using the 'App' in the 'startscreen' property.

     

    The screen always starts on the DHS Homepage. When I turn on a specific value, it transitions to the maintenance window or the maintenance window for summer break 'startscreen'.

     

    Screenshot 2023-11-14 at 2.17.56 PM.png

    Screenshot 2023-11-14 at 2.18.05 PM.pngScreenshot 2023-11-14 at 2.18.13 PM.png

  • charlessexton Profile Picture
    Super User 2024 Season 1 on at
    If(LookUp('Maintenance Window', ID = 1).Status.Value = "Turn Off", 'DHS Homepage','DHS Maintenance Window')&If(LookUp('Maintenance Window', ID = 2).Status.Value = "Turn Off", 'DHS Homepage','DHS Maintenance Window (Summer Break)')

    What do you want the code to do? If the ID is either 1 or 2 then display "DHS Homepage"? Otherwise display "DHS Maintenance Window"?

    Also, where are you putting this code?

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

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Apps

#1
Kalathiya Profile Picture

Kalathiya 428

#2
WarrenBelz Profile Picture

WarrenBelz 374 Most Valuable Professional

#3
MS.Ragavendar Profile Picture

MS.Ragavendar 333 Super User 2025 Season 2

Last 30 days Overall leaderboard