[ANSWERED]Getting the day of the week into a variable
Posted:
Mon Jul 21, 2014 9:34 pm
by HowmaNoid
Is there anyway to get the system day (i.e. Monday, Tuesday, etc) into a viable in Indigo so it can later be spoken in an action? I've been able to get the numeric data into a variable but I really need to name of the day of the week.
Thanks in avance!
H
Re: Getting the day of the week into a variable
Posted:
Mon Jul 21, 2014 10:16 pm
by RogueProeliator
The easiest way (to me) is to use Python's DateTime format string; you can use a "%A" to get the day representation as a string. You can do this in a script or use the built-in action "Insert Timestamp into Variable" in the Variable Actions section (in that case, check to use a custom format and use %A).
I haven't tested this in the Actions, but have used it in Python scripts, should work the same in both places.
Adam