Filter DirectoryInfo files by date in asp.net
问题 I am populating a datagrid control using files in a specified path (DirectoryInfo). I would like to filter the files based on a user specified date range (start date & end date). While search S/O, I found this post, but I am getting an error on DateComparer ( "'DateComparer' is a type and cannot be used as an expression." ) Any other suggestions on how to filter by date? Here is my code: Dim dirInfo As New DirectoryInfo(strDirectoryPath) Dim dStartDate As DateTime = "03/01/2011" Dim dEndDate