File content search c#

I’m trying to implement this feature in my application. Just like in windows, I type into the search box and if the File contents is checked in the settings, than no matter its a text file or pdf/…