Hi All,I want to get the modifed date of my DCR's in the following format yearmonthday (i.e 20091126) while i get it in the following mannerThu Nov 26 11:10:07 2009I tried using Date::Format $modified = `iwattrib $item1 moddate`;$modified=time2str("%Y%m%d", $modified);But its not working.It gives me the result as 19700101 Can anyone help?
chomp($modified = qx(iwattrib $item1 modddate));
use Date::Manip;...chomp(my $modified = qx(iwattrib $item1 moddate));($modified = ParseDate($modified)) =~ s/^(\d{8}).*$/$1/;
Hey Adam Thanks for the reply.I tried using Manip but it gives me some weird timezone errorDate 12/02/09 12:18:19ERROR: Date::Manip unable to determine TimeZone. Date::Manip Date_TimeZone called at C:\iw-home\iw-perl\vendor\lib/Date/Manip.pm line 661 Date::Manip Date_Init() called at C:\iw-home\iw-perl\vendor\lib/Date/Manip.pm line 1395 Date::Manip:arseDate('Thu Nov 26 11:10:07 2009') called at G:\custom_scripts\all_files.ipl line 83