@rho1967 wrote:
Many Thanx,
It works when I refresh the page. But if it has to start itself then it won't be visible. What could this be?
Do I have to place the video on another page and then navigate to another page at a time?
Thank you very much
Raymond
The behavior you're seeing is because Today() and Now() do not continuously re-evaluate on their own - they need deliberate action through a behavior formula (one that starts with "On") to return a new value.
One way to deal with this is to create and set a variable using a timer:
- Put varVisible in the Visible property you want to control
- Insert a timer on the screen, set it to auto-start, repeat, and make it non-visible
- Set the timer's duration to 60000 (one minute) and set its OnTimerEnd code to:
Set(varVisible,
If(
DateDiff(Today(),Now(),Hours) >= 11 && DateDiff(Today(),Now(),Hours) < 14,
true,
false
)
)
Once per minute the app will re-evaluate the expression and toggle the variable & visibility of your control.