Windows Grep saves its search parameters in files with the extension .PAR. These files are in plain text and are similar to .INI files. Here's an example:
[General Search Parameters] Search String=Windows Match Case=False Skip Text Files=False Skip Binary Files=False Search ZIPs=False Whole Words Only=False Count Files First=True Recurse Subdirectories=True Search Mode=0 Text File Format=0 Date Filter Mode=0 Min Date=28/05/00 Max Date=28/05/00 Greater Than Days=7 Less Than Days=7 Size Filter Mode=0 Min Size=1000 Max Size=100000 Less Than Size=1000 Greater Than Size=100000 Field Number=1 Field Start=1 Field Width=100 Separator Char=, [Active File Specifications] 0=*.ini 1=*.inf [Active Directory Specifications] 0=C:\Windows 1=C:\Program Files 2=
Each time Windows Grep loads, it looks for the file default.par. If this is found, the settings in it will be used as the basis for the first search. Pressing the start button on the toolbar will execute the search according to these parameters. Then, when Windows Grep exits, the current search settings are written back to default.par ready for the next time the program is loaded.
Searches can be saved and opened again using the toolbar buttons or menu options so that complex searches can be saved for easy recall later. .PAR files can also be specified on the command line.
If you wish to 'hand roll' your own .PAR files either by hand or by another program, bear in mind that the file does not have to have all sections or entries present. The built-in defaults will be used.
The minimum usable .PAR file is:
[General Search Parameters] Search String=<string> [Active File Specifications] 0=<filespec> [Active Directory Specifications] 0=<dir>