Guys

I found out the issue. My script was failing not in enumeration part but in getfiletime function, This event log file name is having "@" charecter when i removed this charecter it was giving file date and time.

quote:

$ss=GetFileTime ("f:\MOSAIC01MZsec14-9-2003@8-20-5.evt")
? $ss
$ss1=GetFileTime ("f:\MOSAIC01MZsec14-9-20038-20-51.evt")
? $ss1

here $ss1 is giving the output $ss no.

there are thousends of files in the directory I cannot rename all manuelly [Roll Eyes]
_________________________
“I’ll not change you unless you don’t have intention to change yourself” --H:Quran