cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
AdhamFH
Helper V
Helper V

Set timer in visible's property

Hello,

How to set a timer to visible's property, for example i have a text label here and i want to set a timer about 15 minutes and after that the visible will turn to false

test8.PNG

 

 

Thank you

1 ACCEPTED SOLUTION

Accepted Solutions
K-A-R-L
Solution Specialist
Solution Specialist

Hi @AdhamFH ,

Can you please confirm if this is what you want to achieve: 

Timer Visibility.gif

 

 

Screen Code

OnVisbile() Property:

UpdateContext({Visibility:false})

 

Timer of Visibility Code:

AutoStart() and Repeat() = false

OnTimerEnd() Property: 

UpdateContext({Visibility:false})

OnTimerStart() Property:

UpdateContext({Visibility:true})

 Start() Property

If(Label1_2.Text = Label1_1.Text,true, false)

 

 

Hello Label:

Visible() Property

Visibility

 

 

----------------------------------------------------------------------------
Thanks,
K-A-R-L


If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
If you thought this post was helpful, please give it a Thumbs Up.

View solution in original post

3 REPLIES 3
K-A-R-L
Solution Specialist
Solution Specialist

Hi @AdhamFH ,

You can set the visibility of the label as a context variable, this will temporarily hold a piece of information such as the status of the Label's visibility.

Try using this code:

 

On the OnVisible() Property of the Screen where the Label is located set it to:

UpdateContext({Visibility:true})

 

Set the Visible() Property of the Label to: 

Visibility //this is the variable

 

On the Timer's  OnTimerEnd() Property, set it to:

UpdateContext({Visibility:false})

 

 

To quickly test it: set the duration of your timer to "5000".

----------------------------------------------------------------------------
Thanks,
K-A-R-L


If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
If you thought this post was helpful, please give it a Thumbs Up.

hi @K-A-R-L , thank you for your reply, actually i have put a timer to get currentdatetime and display it to my label at the right one

test9.PNG

 

 

and then i want to make a condition if label on the left one is equal to label on the right one then the label "hello" will visible about 15 minutes. Is it possible to do that ?

K-A-R-L
Solution Specialist
Solution Specialist

Hi @AdhamFH ,

Can you please confirm if this is what you want to achieve: 

Timer Visibility.gif

 

 

Screen Code

OnVisbile() Property:

UpdateContext({Visibility:false})

 

Timer of Visibility Code:

AutoStart() and Repeat() = false

OnTimerEnd() Property: 

UpdateContext({Visibility:false})

OnTimerStart() Property:

UpdateContext({Visibility:true})

 Start() Property

If(Label1_2.Text = Label1_1.Text,true, false)

 

 

Hello Label:

Visible() Property

Visibility

 

 

----------------------------------------------------------------------------
Thanks,
K-A-R-L


If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
If you thought this post was helpful, please give it a Thumbs Up.

View solution in original post

Helpful resources

Announcements
PA_User Group Leader_768x460.jpg

Manage your user group events

Check out the News & Announcements to learn more.

Power Query PA Forum 768x460.png

Check it out!

Did you know that you can visit the Power Query Forum in Power BI and now Power Apps

Carousel 2021 Release Wave 2 Plan 768x460.jpg

2021 Release Wave 2 Plan

Power Platform release plan for the 2021 release wave 2 describes all new features releasing from October 2021 through March 2022.

PowerPlatform 768x460.png

Microsoft Learn

Check out our new Discover Your Career Path blog post series and get all the details.

Users online (2,845)