I have a menu that consists of the items in a directory. What I NEED is to filter out a specific file. The file that I need to NOT show up in this list is called WIPSAdmin... how do I keep that from showing up in the list? Here is the code:
string[] directories = Directory.GetDirectories(@"\\srvusadcweb01\wips_test"); var validDirectories = from string directory in directories where Path.GetFileNameWithoutExtension(directory) != "WIPSDATA" select directory; foreach (string fileName in validDirectories) { this.Sites.Add(new Folder() { PathName = fileName }); }