1
Answer

Get certains files from a folder sing C# and/or LINQ

yamid

yamid

7y
230
1
Hi All,
 
I want to get "full path" of all files that 
1.  have the extension "*.bpp" (except one file that ends with 279.bpp), and
2. their sizes should be greater than 50 kb.
I have this code, but I can not add another filter based on the file size 
 
  1. var files0 = Directory.GetFiles(mydirectoryPath, "*.bpp").Where(name =>!name.EndsWith("279.bpp");   
Please note that I need the full path of all files that pass those two filters.
Answers (1)