I have seen scripts that search for a specific entry eg this one;
'On Error Resume Next
Const ForReading = 1
SearchString = Inputbox ("Enter the Entry Value")
Set objExcel = CreateObject("Excel.Application")
objExcel.Visible = True
objExcel.Workbooks.Add
intRow = 2
objExcel.Cells(1, 1).Value = "Server Name"
objExcel.Cells(1, 2).Value = "Target Entry"
Set objFSO = CreateObject("Scripting.FileSystemObject")
Set InputFile = objFSO.OpenTextFile("MachineList.Txt")
Do While Not (InputFile.atEndOfStream)
strComputer = InputFile.ReadLine
objExcel.Cells(intRow, 1).Value = strcomputer
GetHostsEntry
intRow = intRow + 1
Loop
objExcel.Range("A1:E1").Select
objExcel.Selection.Interior.ColorIndex = 19
objExcel.Selection.Font.ColorIndex = 11
objExcel.Selection.Font.Bold = True
objExcel.Cells.EntireColumn.AutoFit
Wscript.Echo "Done"
'************************************************************************************************
Sub GetHostsEntry
Set objFSO = CreateObject("Scripting.FileSystemObject")
Set objFile = objFSO.GetFile("\\" & strComputer & _
"\c$\WINDOWS\system32\drivers\etc\hosts")
If objFSO.FileExists(objFile) Then
Set objHostsFile = objFSO.OpenTextFile(objFile, ForReading)
Do Until objHostsFile.AtEndOfStream
strEntry = objHostsFile.Readline
SearchEntry = InStr(strEntry , SearchString)
If SearchEntry > 0 Then
strCurEntry = strEntry
objExcel.Cells(intRow, 2).Value = strCurEntry
End If
Loop
objHostsFile.Close
Else
objExcel.Cells(intRow, 2).Value = "Hosts File Not Exist"
End If
End Sub