get yesterday date

Help for those learning Tcl or writing their own scripts.
Post Reply
p
paull
Voice
Posts: 6
Joined: Mon Dec 01, 2008 10:18 am

get yesterday date

Post by paull »

To get the date I use:

Code: Select all

proc getDate {} {
    set temp [clock format [clock seconds] -format "%Y-%m-%d"]
    return $temp
}
How can i get yesterdays date?

Thanks
t
tsukeh
Voice
Posts: 31
Joined: Thu Jan 20, 2005 6:22 am

Post by tsukeh »

Code: Select all

proc getDate {} {
    set temp [clock format [clock scan "yesterday"] -format "%Y-%m-%d"]
    return $temp
}
Post Reply