Hi,
In my calender widget, I use
Code:
$#C0SRd#>0?#C0SRdd#$$#C0SRd#=0&&#C0SRh#>0?#C0SRhh#$$#C0SRd#=0&&#C0SRh#=0&&#C0SRm#>0?#C0SRmm#$
Basically, I want to see time left from my next meeting.
The problem is, in my calander, I have both start time and end time. ( For example, Meeting with John, start-14:00, end-15:00).
The problem is with this code, as soon as start time begins(i.e. at 14:00), zooper possibly takes the end time (i.e. 15:00) as my C0SRmm and starts showing time left with that respect. So, w.r.t. the example above, if it is 13:05 on the meeting day, it will show 55 min. Which is expected.
But then, if the time is 14:00<current time< 15:00 , e,g. 14:25, it will show 35 min, i.e. time left from the end time...which I don't want.
Any help please?
Are you sure that's the behavior? For me, during an event, #C0SRm# counts the number of minutes from the event's starting time. In your example, for an event starting at 14:00, at 14:25 it will show 25 (really 26 as I see in practice).
ewcrider said:
Are you sure that's the behavior? For me, during an event, #C0SRm# counts the number of minutes from the event's starting time. In your example, for an event starting at 14:00, at 14:25 it will show 25 (really 26 as I see in practice).
Click to expand...
Click to collapse
Sorry...you are right...thats exactly what I get......and I don't want it. I just want to know when my meeting is....not how long the meeting is going.
Barud said:
Sorry...you are right...thats exactly what I get......and I don't want it. I just want to know when my meeting is....not how long the meeting is going.
Click to expand...
Click to collapse
Ok, what do you want it to say instead? Or do you want it to say nothing, or say something like "ongoing"?
I also have a countdown to my next event. I solved this problem using two copies of the countdown, one using event 0 and one using event 1. When event 0 is going on, I hide the countdown for 0 (by setting font size to zero using conditionals in the advanced parameters) and show the countdown for event 1. Otherwise, I hide countdown 1 and show countdown 0.
My test if event is occurring: #DyyyyMMddHHmm#>#C0SyyyyMMddHHmm#
If you just want to hide the countdown, you could add this to your existing conditionals.
Related
Hello everyone,
I know the alarm free date #SAD...# is a beta feature at the moment, but I've run into a bug with it that I thought you should know about.
I have a section on a widget where I show the next alarm date and time, but I want to also show bedtime, which would be the alarm minus 8 hours. I know for standard dates, I can do something like #D-480...# if I want to subtract 8 hours. I can even do math within the variable, such as #D-$(8*60)$...# to subtract 8 hours. When I try this same sort of thing with the alarm free date variable, I find that it compounds amount added or subtracted each minute until something causes it to reset.
To make a simple example, if my alarm is set for 3:30 on Monday, and if I want to display the alarm time with 1 minute subtracted from it, I use #SAD-1 P:mm p#, and I should get 3:29am on Monday. It works correctly for the first minute, but as soon as another minute passes, I see that the the adjusted alarm time now shows 3:28am. So every time a minute passes, the adjusted alarm time gets multiplied by the number of minutes passed since I saved the widget. If I subtract 2 minutes at a time, then I see the time drop by 2 minutes as each minute passes. If I do 8 hours, then, well, it gets very strange very quickly.
I have noticed that the adjusted alarm time will reset from time to time, going back to the correct calculation for a minute, but I'm not sure of what causes the reset. Sometimes it will go back to the correct calculation after editing the widget, and sometimes it won't. Other times it will go back to the correct calculation after my screen has been off for a little bit and then I turn the screen back on, but not every time. Also, it looks like it may not add or subtract additional increments while the screen is off. Again, with my example of subtracting 1 minute, if my screen timeout is 2 minutes, then by the time the screen turns off, I'll see 3 minutes subtracted in total. If I turn the screen back on 10 minutes later, it will still show the 3 minutes subtracted. The next minute that the screen is on, it will either reset to 1 minute being subtracted, or it will continue to 4 minutes subtracted.
FYI, I'm on a Samsung Galaxy Note 3, Android version 4.4.2, Sprint, rooted, but I am running on stock ROM and kernel.
I hope that this helps pinpoint where the bug may be. Please let me know if any other information is required.
Thanks,
Jeremy
Same problem here.
I'd like to make a complex test, i.e. several conditions.
More precisely, I'd like to display the remaining time to next event, under certain conditions. Here is a first example :
$0<#C0sRd#?#C0sRd 'day'#$$1<#C0sRd#?s$ $0<#c0srh#?#C0srh 'hour'#$$1<#c0srh#?s$ $0<#c0srm#?#c0srm 'min'#$.
This line displays the time to next event, but does not displays '0 day' or '0 hour'. But, in case the next event is a full day event (beginning at 12AM) I'd like to display the time to the second next event.
Then I add a test to see if next event begins at 0 hour in the morning :
$0<#C0EH#? #C0sRd 'j'# #C0srh 'h'# #c0srm 'min'#$:#C1sRd 'j'# #C1srh 'h'# #c1srm 'min'#$.
But this line displays '0 day' or '0 hour'.
How can I write the command line that takes both advantages, meaning displays the time to the second next event if next event is full day, AND does not diplay '0 day' or '0 hour' ?
Thank you for your help...
You can use #C0D# and use "&&" (logical AND) to combine conditionals. #C0D# should equal "1" if the next event is all day otherwise it should give you "0".
You can try this:
Code:
$#C0D#=0&&#C0SRd#=1?#C0sRd# day $$#C0D#=0&&#C0SRd#>1?#C0SRd# days $$#C0D#=0&&#C0SRh#=1?#C0SRh# hour$$#C0D#=0&&#C0SRh#?#C0SRh# hours $$#C0D#=0&&#C0SRm>0#?#C0SRm# min$$#C0D#=1&&#C1SRd#=1?#C1sRd# day $$#C0D#=1&&#C1SRd#>1?#C1SRd# days $$#C0D#=1&&#C1SRh#=1?#C1SRh# hour$$#C0D#=1&&#C1SRh#?#C1SRh# hours $$#C0D#=1&&#C1SRm>0#?#C1SRm# min$
I haven't tested this so you may need to tinker with it to get it to work properly. I rewrote parts of your code to eliminate useless blank spaces.
It works fine, thanks a lot !
However, there is still one problem to tackle. Sometimes, I have the following case:
- the first event is an all day event, for today
- the second event is already begun
Then I want to know the time remaining until the 3rd event. Actually, what I want is the time until the next event that is not yet begun.
But the values of #C1SRh# and #C1SRm# give the time between the beginning of the second event and the current moment : it should be negative as the second event is already begun, but it's positive so it's not valuable.
Does anyone know a reliable way to obtain the time remaining until the beginning of the next event that is not yet begun ?
Thanks for your help.
I tried this, to simplify the problem:
$((#DD#-#C0SD#)*1440+(#DH#-#C0SH#)*60+(#Dm#-#C0Sm#))<=0?#C0SRd# d #C0SRh# h #C0SRm# min.$$((#DD#-#C0SD#)*1440+(#DH#-#C0SH#)*60+(#Dm#-#C0Sm#))>0&&((#DD#-#C1SD#)*1440+(#DH#-#C1SH#)*60+(#Dm#-#C1Sm#))<=0?#C1SRd# d #C1SRh# h #C1SRm# min.:#C2SRd# d #C2SRh# h #C2SRm# min.$
It calculates the number of minutes since new year of the current moment and compares it with the numer of minutes since new year of the first and the second event. (1440=60*24)
If current number of minutes minus 1st event's is negative, it means that the 1st event is not yet begun: then display the remaining time to 1st event.
If not and if current number of minutes minus 2nd event's is positive, it means the 2nd event is not yet begun: then display the remaining time to 2nd event; else display the remaining time to 3rd event.
This seams good to me, but is always displays the time time 3rd event : "#C2SRd# d #C2SRh# h #C2SRm# min."
Is there anything wrong with my formula?
Actually, it works if I use one ( and not 2...
$(#DD#-#C0SD#)*1440+(#DH#-#C0SH#)*60+(#Dm#-#C0Sm#)<=0?#C0SRd# j #C0SRh# h #C0SRm# min.$$(#DD#-#C0SD#)*1440+(#DH#-#C0SH#)*60+(#Dm#-#C0Sm#)>0&&(#DD#-#C1SD#)*1440+(#DH#-#C1SH#)*60+(#Dm#-#C1Sm#)<=0?#C1SRd# j #C1SRh# h #C1SRm# min.:#C2SRd# j #C2SRh# h #C2SRm# min.$
Hello,
I am looking to create a countdown to a day of week and hour of day. example: Target is "Tuesday 01:00 PST" so on "Wednesday at 16:00" the timer will read "6 d 9 hrs" and "Monday at 18:00" 0 d 7 hrs.
Starting writing it out and its displays "1" on Monday, but I quickly found out I was on the wrong track since I couldn't reconcile hours
$(#DF#)=3?(0)$$(#DF#)<3?(3-#DF#)7+3-#DF#)$
[email protected] said:
Hello,
I am looking to create a countdown to a day of week and hour of day. example: Target is "Tuesday 01:00 PST" so on "Wednesday at 16:00" the timer will read "6 d 9 hrs" and "Monday at 18:00" 0 d 7 hrs.
Starting writing it out and its displays "1" on Monday, but I quickly found out I was on the wrong track since I couldn't reconcile hours
$(#DF#)=3?(0)$$(#DF#)<3?(3-#DF#)7+3-#DF#)$
Click to expand...
Click to collapse
Assuming your target day of the week and hour does not change, can't you do something similar for the hours but use #DH# instead of #Df#:
Code:
$#DH#=1?0$$#DH#<1?1$$#DH#>1?(24+1-#DH#)$
The only problem with this is that your timer will only change at the top of the hour (for example, from 18:00 to 18:59 your timer will continue to read "7 hrs"). Don't know if that's what you want.
Also your code for the number of days needs to be adjusted to insure that each condition is both mutually exclusive (as is if #Df#=3 your code is going to give "(0)7") and also takes into account the time:
Code:
$#DF#=3&&#DH#<=1?0$$(#DF#)<3?(3-#DF#)$$#DF#>3&&#DH#>1?(7+3-#DF#)$
[email protected] said:
Hello,
I am looking to create a countdown to a day of week and hour of day. example: Target is "Tuesday 01:00 PST" so on "Wednesday at 16:00" the timer will read "6 d 9 hrs" and "Monday at 18:00" 0 d 7 hrs.
Starting writing it out and its displays "1" on Monday, but I quickly found out I was on the wrong track since I couldn't reconcile hours
$(#DF#)=3?(0)$$(#DF#)<3?(3-#DF#)7+3-#DF#)$
Click to expand...
Click to collapse
jr67 said:
Assuming your target day of the week and hour does not change, can't you do something similar for the hours but use #DH# instead of #Df#:
Code:
$#DH#=1?0$$#DH#<1?1$$#DH#>1?(24+1-#DH#)$
The only problem with this is that your timer will only change at the top of the hour (for example, from 18:00 to 18:59 your timer will continue to read "7 hrs"). Don't know if that's what you want.
Also your code for the number of days needs to be adjusted to insure that each condition is both mutually exclusive (as is if #Df#=3 your code is going to give "(0)7") and also takes into account the time:
Code:
$#DF#=3&&#DH#<=1?0$$(#DF#)<3?(3-#DF#)$$#DF#>3&&#DH#>1?(7+3-#DF#)$
Click to expand...
Click to collapse
First off, thank you for your help.
I combined your thoughts and tweaked it a little so the display reads 6 D / 11 H which is currently the time until next Tuesday at 4:00 PST in, Since I am EST I had to adjust for that. Interestingly you used #DH# which seems to look at Monday as the first day of the week where I used #Df# which uses Sunday.
Code:
$#DF#=2?6$$(#DF#)<2?(2-#DF#)$$#DF#>2&&#DH#>4?(7+2-#DF#)$-D/$#DH#=1?0$$#DH#<1?1$$#DH#>1?(24+4-#DH#)$-H
In EU countries, British summer time ended last night and the clocks went back 1 hour. My phone shows the correct time and changed automatically. I use an app called Tasks https://play.google.com/store/apps/details?id=ch.teamtasks.tasks.paid that I have been using for a while is now, and it's now longer working correctly (and another similar app is doing the same). When I input a time for the task to alarm the time displayed goes back one hour, so for example I have a task that will sound at 6:15 am tomorrow, but the time that it will go off is 5:15 am. Any idea's why this is happening, I thought it might have been the app, but I have tried tow different ones. They both synchronise with Google. The only way to 'fix' it would be to set the time to remind me at 7:15 am.
My phone is rooted on stock rom.
Now I have text like this: $#C0SEEE##C1SEEE#!=#DE#?#C1Sdd.MM# #C1SEEE#$ $#C1EHHmm#=0000?-:[tl]#C1SHH:mm#-#C1EHH:mm#[/tl]$$#C1EEEE#=0000?#C1TITLE#: [tr=10]#C1TITLE#$$#C1LOC#=?:#C1LOC#[/tr]$
this show me calendar entry with day,hour and name. But if meet is all day this not show hour (like 00:00 -00:00) and this is OK. But if something in calendar takes longer then one day (ex. trip since 28.09-5.10) I see only firs day (ex. 28.09 mon. - holiday) HOW do that if something take longer then one day it show full range ex. "28.09 mon. - 5.10 thu. - holiday" but still if something is only one day it show only this day.