PowerShell script to search "string" in files
Let’s say that you have a log folder contain a lot of log.txt files and you want to find out which log file contain a particular “event” or “string”. The below script can accomplish just that
Get-ChildItem c:\log | select-strings “string”