Text In A Zip

Written By Mark Taylor

Please vist www.mtzone.co.uk for the latest version.

Have fun, if you like it (or even hate it), or have a idea to make it better, then please e-mail me.

I can be contacted at tiaz@mtzone.co.uk This program cannot be sold, and is provided 'as is'. Lots of the code, came from various sites and Authors. But mainly from Planet Sorce Code , and VBnet, The Visual Basic Developers Resource Centre , and Info Zip

What does "Text In A Zip" do?

=============================

If like me you download lots of files from the Internet (either from WWW or Newsgroups), it can be a problem to remember what file contains what, as lots of authors still use 8.3 file names. So "Text In A Zip" tries to helps out - it only works on "Zips", as this is the dominant file format at this time.

Within most of these files there are a number of 'Text File Format' files, these generally have a file extension similar to one of the following (*.NFO, *.DIZ, *.TXT, *.DOC, *.PRN), there are of course others, in fact you can specify the formats you wish to examine, from within "Text In A Zip".

"Text In A Zip" will allow you to enter a Search String (or a file, containing a list of strings), also a path needs to be entered. Once this information is entered, "Text In A Zip" will then search your files, trying to match your Search String against one of the files you defined to be searched.

If a file contains a match, the file name is transferred to a file list, this will continue until either all files have been searched or you stop the scan.

Once you have your list of files, you can choose to either examine the file with the associated program (i.e. Winzip) or use the Internal Viewer, I'd recommend the latter, as its faster and each time your Search String is found, it will be changed to the colour Red+Bold+Italicised, so you should be able to find it. All files that match your extensions will be loaded into the Internal Viewer, once you have read the text you can then extract the files if so desired.



For System Administrators
=========================

If you want some way of checking what a user is downloading then "Text In A Zip" may have the answer!.

"Text In A Zip" can be run from the Command Line, and requires no user input, you enter a path or Network path to start from, and either a Search String, or my recommendation would be to use a File List of Search Strings, and then finally a list of file extensions to search (default list is - *.NFO *.DIZ *.TXT *.DOC). "Text In A Zip" will then scan the files and produce a detailed log, of path and the file name is.



Command Line Switch's
=====================

"Text In A Zip" can be run from the command line i.e. from a dos box, there are only four (4) commands that can be used. These are - "-Search=", "-Folder=", "-Audit" and "-Extensions=" these can be used in a number of combinations. Certain combinations means that "Text In A Zip" will not display any information, i.e. it runs in quite mode.

-Audit
If this is used, then there must be a file called "Audit.TXT" in the same place as "Text In A Zip.EXE" and the format is as follows, each line can contain a Search String, remember to make sure there are no blank lines in the file, unless you want to search for blanks of course. This can be used on it own, or if running from a Command Line then it must be used with the "-Folder=" command.
This command is ideal for a network administrator, who could schedule a batch file to run at night and search a network drive, for certain files that users have downloaded, for example files from pirate sites or "Crack" files.

-Search=
This will be the string that needs to be searched for, this can be used on its own, for example if you always search for the same string but in different locations, it can be combined with the "-Folder=" command.

-Folder=
This can be either a folder, drive or a network drive, this is the starting point of the search, if this command is used it MUST be combined with either "-Audit" or "-Search=" commands.

-Extensions=
This can be a line of file extensions that you wish to try and find the Search String within.


How it works
============

"Text In A Zip" is very easy to use, but it does have tool tips, and it also produces a log of any files that matched the search string or Audit file.

I'll run through quickly what each part does though -

Search String -- Enter the desired String that you wish to find

Search Path -- Either type in a path, or click the entry box, and a file selector will be pop up.

File Extensions -- Enter the type of files you want to search, these should be text based, and separated with at least one space, and the format of the Extension entry is "*.TXT" (without the quotes)

Use Audit File -- If checked, a file called "Audit.TXT" is used instead of a Search String. The format of the file is one string per line.

Use Internal Viewer -- This is a Internal viewer built into "Text In A Zip", I would recommend using it as it has a number of advantages over using a Zip associated program. These are, all files that match your chosen extensions are loaded into the viewer, and each case of your chosen Search String is highlighted in RED+BOLD+Italic, from with in the viewer you can also choose to extract the file. You can now also use either the Right Mouse button or Control - F, to navigate through multiple match's

Include Sub Folders -- If checked, then SubFolders will be searched.

Matched Files -- This is a list of files that have matched your Search String, Clicking on a file will take you to either the Internal Viewer (See Above) or the associated program for Zip files.

Scan Button -- Start scanning.

About Button -- Shows information about the program, you can also Register from within the About Dialog.

There is some information shown while scanning files, this is the total number of files scanned, number of files that match your Search String and the file being examined.