c# foreach iteration but only within specified date : I want to get files iteratied thru a directory but only from last two months,
so I got:

...directory di code here ...

DateTime from_date = DateTime.Now.AddMonths(-2);

DateTime to_date = Datetime.Now;

...

foreach (var filename in di.EnumerateFiles("*.SS*").Where(filename.ToString()=>filename.ToString().LastWriteTime >= from_date && filename.ToString().LastWriteTime <= to_date))

{

...code here..

}


Well, it doesn't like that foreach loop for some reason. Is there a correct way of doing this?