March 11, 2012| | 0 Comment
File Search (By Extension) in C#
The article demonstrates how to search the files from the specified path of directory based on which type of file are you finding. This can be useful further if you want to code for finding the files from sub-directories.
o One TextBox Control
o One ComboBox Control
o One ListBox Control
o Two Button Control
Step 2: Write Code section for accessing path as String.
Step 3: Now, select Extension Type from ComboBox Control for Searching Files.
Step 4: Now, Code to search the desired files from given path.
Step 5: Click the “Search” Button Control.
Step 6: If intended results found then the Name of that files are displayed in ListBox Control.
see Intended Result Section.
In this article, we have seen how we to find the file names (of particular extension) from specified directory using C#.