How to make time compare using minutes

Dear all
im trying to make app with function true or false if time of device is with range of time in test with 2 min
any advice to do that

can you give an example

10:40:35
10:41:20
status true because its with in 2 minutes
10:40:35
10:42:20
status false because its with out 2 minutes

This is also true. It would be false if it was > 10:42:35.

2 Likes

i need the blocks to use it at it is

I dont know how you will compare, But here i used time difference between system time and call now(I hope both will give you same time, anyhow extract the information),and found working perfectly…

If the time difference between the two mode is 0 and 2, label will say, You are in correct time if not label will sat error…

1 Like

the first time device one
the second time is text or time picker

This block working fine… Slightly i have updated…

When screen Initialize.

When Set timer got selected & pressed Button2 (If time difference is more than 2 min):

When Set timer got selected & pressed Button2 (If time difference is less than 2 min):

could you plz share aia

Multiple screens are there, So i would like to share the screen as ais file

Gowri_sankar_Screen2.ais (507 Bytes)

Here is the screen2.ais

Try and let me know

ok
i will do