How can I compare to system date?
#1
Can I pull an infolabel that will allow me to compare If system date = monday, do this... etc.

I need to be able to pull just day of the week. not the full date.
Image
To learn more, click here.
Reply
#2
igotdvds Wrote:Can I pull an infolabel that will allow me to compare If system date = monday, do this... etc.

I need to be able to pull just day of the week. not the full date.
hmm stringcompare() would work, thing is that you would have to do keep all languages in mind.
Donate: https://kodi.tv/contribute/donate (foundation), 146Gr48FqHM7TPB9q33HHv6uWpgQqdz1yk (BTC personal)
Estuary: Kodis new default skin - ExtendedInfo Script - KodiDevKit
Reply
#3
phil65 Wrote:hmm stringcompare() would work, thing is that you would have to do keep all languages in mind.

But system.date will pull Monday, October 11, 2010.

How could I compare Monday to system.date?

How could I tackle different languages?
Image
To learn more, click here.
Reply
#4
stringcompare can handle localized labels, but i'm not 100% sure
if substring (which is what you need, i guess) can do that too.

anyway, give this a shot:
SubString(system.date,$LOCALIZE[11])


edit:
yep, works fine at my end.
Do not PM or e-mail Team-Kodi members directly asking for support.
Always read the Forum rules, Kodi online-manual, FAQ, Help and Search the forum before posting.
Reply
#5
Ok heres what I am using

<visible>StringCompare(Window(Home).Property(NextAired.1.Airtime),$LOCALIZE[20342])</visible>

Window(Home).Property(NextAired.1.Airtime) returns Monday at 09:00 pm

$LOCALIZE[20342] returns Monday

I cant get it to show when the two are compared and return true.
Image
To learn more, click here.
Reply
#6
which is WHY ronie used substring mate Wink
Reply
#7
bad way there, the script will always give you monday for this information, so don't use localized Wink
Reply
#8
spiff Wrote:which is WHY ronie used substring mate Wink

SubString didnt work either.

ppic Wrote:bad way there, the script will always give you monday for this information, so don't use localized Wink

I am wanting to show the shows ONLY when the string from the script shows Monday, then have another page for when the string equals Tuesday, etc.
Image
To learn more, click here.
Reply
#9
other way i see, i can push you a list of today aired show, will save you from adding several string compare for all properties id !

with a list, using substring will be fine Wink, just one compare to do, instead of each item.
Reply

Logout Mark Read Team Forum Stats Members Help
How can I compare to system date?0