C# .NET - Search Functionality - Asked By Sai Yadav on 29-Dec-13 11:25 AM


On click of button search a specific line from selected folder.

I have a text box and text box contains particular line or word and on click of button i want to search word from selected folder.


Ex.

I have selected a folder and stored the folder name in particular variable or label.
Folder contains more than one files.

Now i have entered particular text or Line into text box so i want to search this line from all files that contain in selected folder.

Thanks....
Robbe Morris replied to Sai Yadav on 30-Dec-13 08:14 AM
Assuming you only want to open text files in  your search, these will help get you started:

https://www.nullskull.com/a/747/net-systemio-read-and-write-files-compared-to-scriptingfilesystemobject.aspx
https://www.nullskull.com/faq/241/use-streamreader-to-read-a-text-file-in-net.aspx