Guest solidarity Posted May 13, 2004 Posted May 13, 2004 I'm sorry if this has already been answered before, but here goes. The macro @YEAR will give you a four-digit year. Is it possible to get a two-digit year? Thanks, Stu
Developers Jos Posted May 13, 2004 Developers Posted May 13, 2004 You mean something like: StringRight(@YEAR,2) SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past.
Helge Posted May 13, 2004 Posted May 13, 2004 (edited) You mean like, 2004 = 04 ? Then try this : $YEAR = StringRight(@YEAR, 2) MsgBox(64, "", $YEAR) Good luck ! EDIT : Holy cow, JdeB You mean something like: StringRight(@YEAR,2)(I became busy when I started to write my post, so it got delayed..) Edited May 13, 2004 by Helge
Nutster Posted May 18, 2004 Posted May 18, 2004 Another option, to keep it strictly numeric:$y = Mod(@YEAR, 100)Take a look at the MOD function in the help file. David NuttallNuttall Computer Consulting An Aquarius born during the Age of Aquarius AutoIt allows me to re-invent the wheel so much faster. I'm off to write a wizard, a wonderful wizard of odd...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now