Greetings, I am having a problem with Perl providing me the correct date when I subtract 86400 from the date. This is only happening when I set the computer's system's date to today's date. If I set the system's date to tomorrows date or yesterday's date it works fine. My code is:
$TIME = timelocal (0,0,0,$end_day,$calc_month,$calc_year); $new_time = $TIME - 86400; ($sec,$min,$hr,$dom,$month,$year,$wday,$yday,$isdst) = localtime($new_time); $yday = sprintf("%02d:,$dom); $yyear = $year + 1900; $ymonth = sprintf("02d:,$month + 1); $today = $ymonth.$end_day; $yesterday = $ymonth.$yday; I am running Windows NT. When I run this with my system = today's date(04/09) $today = 0408, $yesterday = 0406. ($yesterday should be 0407) When I run this with my system = yesterday's date (04/08) $today = 0407, $yesterday = 0406. when I run this with my system = tomorrow's date (04/10) $today = 0409, $yesterday = 0408. Thank you for your help, -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]