home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
DP Tool Club 24
/
CD_ASCQ_24_0995.iso
/
vrac
/
cfind17.zip
/
CFIND.DOC
next >
Wrap
Text File
|
1995-06-10
|
16KB
|
364 lines
CFind
─────
v 1.7
Copyright 1995
CraigerWare Enterprises
CFind Page 1
Table of Contents
─────────────────
Introduction ....................................................... 2
Installation ....................................................... 2
Syntax ............................................................. 3
Examples ........................................................... 4
Registration Policy ................................................ 5
About CraigerWare .................................................. 6
Acknowledgements ................................................... 6
Revision History ................................................... 7
Registration Form .................................................. 8
CFind Page 2
Introduction
────────────
CFind was originally a program I wrote for work, to help some of our
employees find data within large database files, while maintaining
simplicity and virtually no learning curve. We wanted anybody to
be able to find data based on looking at a one page "syntax" sheet.
I know there are many, many utilities that perform these same
functions, but most are either shareware or commercial, and this
utility was to be used on 30+ computers, so I wrote CFind to
eliminate both the need for carrying a diskette around, and to
avoid registering/buying 30+ copies of identical software. CFind
is easy to use, accurate, and, I think, intuitive. CFind has
evolved quite a bit since it's inception, and will probably go
through one more release. Upgrade plans include: the ability to
search for hex or binary data; interactive entry of options; and
possibly increased performance. I also tutor C programming, so it's
unlikely that I will ever incorporate assembler into CFind, therefore
it's also unlikely that CFind's performance will drastically improve.
I feel it is quite quick as it sits, so there isn't much room for
improvement anyway <grin>. Please feel free to use it for as long as
you like, free of charge. I will accept donations, mostly to
encourage me to write more utilities of this kind, but also because
programmers always need to purchase more tools, and it gets expensive
writing 'freeware' <grin>. If you do decide to register CFind, I
will supply you with a key file that will eliminate the "unregistered
version" message upon program startup, and allow you to rest assured
that your software karma will remain on the positive side.
Installation
────────────
Installation is simple enough. To be able to use CFind from any
DOS prompt, merely copy it into a directory that's already included
in your path. I use C:\UTILS, which is where I keep lots of these
sorts of programs. If you decide to register, you MUST copy the
CFIND.KEY file into the same directory as CFIND.EXE, so that CFind
will be able to locate it's registration information.
CFind Page 3
Syntax
──────
As stated before, CFind is intuitive and very easy to use. The
complete syntax is:
CFIND <filename.exe> "text to search for" [/S] [/N] [/C]
CFIND /? or CFIND
will provide a brief help/syntax screen.
We will now discuss each of these options in detail.
<filename.exe> should be fairly obvious. One note in particular
is that you may use DOS wildcards (*/?) to include groups of files
in the search.
"text to search for" is, of course, the text you are looking for in
the above selected files. You should get in the habit of using
the quotation marks to enclose the text, because they will be
required if you ever need to search for a string of text that
contains a space character. DOS uses the space character to
find program options, but anything enclosed within quotes is
considered only one option. The quotes are entirely optional,
provided you do not search for text containing spaces.
[/S] is an optional parameter that will cause CFind to search all
subdirectories that are 'under' the current directory.
[/N] is an optional parameter that will remove any prompts CFind
may generate. Normally, CFind will pause after each successful
text find, and allow you to stop or continue. This option
disables this pause so you may use the DOS redirection ">" to
route the report to a file or printer. Think of it as a batch,
or 'NoPrompt' switch.
[/C] is the last optional parameter which will turn on case
sensitive searching. In other words, if you want to find "Text",
but not "text", use the /C option. When you use the /C option,
the report output is in lowercase, but do not be alarmed, CFind
is not modifying any files, just converting everything to small
letters to make it quicker and easier to find matching text.
CFind Page 4
Examples
────────
CFIND *.EXE "COPY"
Will find all instances of "Copy", "copy", "COPY", etc., in any
.EXE files in the current directory.
CFIND *.EXE "COPY" /S
Will find all instances of "Copy", "copy", "COPY", etc., in any
.EXE files in the current directory and all child subdirectories.
CFIND *.* "Copy" /S /C
Will find all instances of "Copy" in any files in the current
directory and all child subdirectories. Will NOT find "COPY" or
"copy", as it is a case-sensitive search.
CFIND *.* "Copy" /S /C /N > FINDCOPY.TXT
Will find all instances of "Copy" in any files in the current
directory and all child subdirectories. Also, the /N option
suppresses all prompts, and the "> FINDCOPY.TXT" on the end
redirects the output to file FINDCOPY.TXT in the current directory.
CFIND *.C "Craig" /N > LPT1
Will find all instances of "craig" (regardless of case) in all
files with an extension of C in the current directory, and prints
them on LPT1.
CFIND *.TXT "Craig" /C > LPT1
Will find all instances of "Craig" in all files with an extension
of TXT in the current directory, and prints them on LPT1. Note
the lack of the /N option. This means that you will have to press
a key after each find, even though the report is going to LPT1.
Note: All options/switches are insensitive to case. You may use
/N or /n interchangeably. Also, the order of the switches is
unimportant, although they MUST be the last thing on the command
line. The first parameter must always be filename, second must
always be search string, then the switches can be in any order.
CFind Page 5
Registration
────────────
CFind is free for private, personal use on your own computer, provided
you are not using it for business or corporate gain. Sysops are
encouraged to distribute CFind on BBS's, and everyone is encouraged
to share CFind, provided all documentation is included within the
archive. I use LZH for distribution, but any archive format is
acceptable. ZIP comments and advertisement files are OK, too, for
if people didn't pass BBS numbers around, nobody would know where
to call. Distribution of CFind key files is strictly prohibited,
however, and is a violation of United States copyright law. This
will hopefully not be a problem, as I'm releasing the executable
version of the program as freeware. Any registrations will also
provide the benefit of free lifetime upgrades, and tech support via
the CraigerWare support BBS. Corporations, businesses, and
individuals who wish to encourage "starving programmers" are
encouraged to register CFind per the following rates. If you
are a FidoNet member, I will be happy to "crash" your key to you.
You may call my BBS after sending your payment, leave me a note, and
after I receive payment, I will attach a key file to a message to
you. Alternatively, if you run a BBS, please indicate if you would
like me to upload the key to you. Last resort is that I will mail
the key to you, on a 3.5" low density disk.
Private/noncommercial: $3 US
This is merely a donation registration. I will provide you
with a key file that indicates that you are the legal owner
of this copy of CFind, and you may use it anywhere you wish,
provided you do not use it in a commercial environment, and
you do not distribute the key file.
Individual Commercial: $5 US
You may use CFind on any one computer. CFind may not be
copied within your organization without purchasing the site
license below. You are expected to treat CFind as you would
treat any other commercial software application.
Site Commercial: $100 US
You may use CFind on an unlimited number of computers within
your organization. You are not allowed to transfer CFind
outside of your organization, but you may freely copy and
distribute CFind among your own, company owned computers.
C Tutoring: $50 US
This option not only includes a key file to identify you as
a legal user of CFind, but you will also be provided with
the TurboC source code to the program. This is not a complex
program, but it does have many good examples of MS DOS specific
C programming techniques. It is invaluable for any beginning
C programmer who has questions about recursive function calls,
file sharing, multitasker awareness, and is a very good example
of readable and acceptable C programming style.
CFind Page 6
About CraigerWare Enterprises
─────────────────────────────
CraigerWare Enterprises was founded in 1989, when I began to teach
myself C during slow periods at work. At the time, I was programming
on both an IBM S/38 and an IBM AS/400, using RPG3, RPG400, and COBOL.
I quickly tired of those languages because of assorted limitations
inherit in each language. My first language on a PC was BASIC, as is
most people's, but I also soon tired of it's bloated and slow .EXE
files, not to mention it's lack of versatility at the time. PCC, by
Mark DeSmet, was my first compiler for C programming, and it provided
me with an excellent foundation of how C works. I also learned a lot
from the Waite series of books on TurboC, which are easy to read,
provide lots of examples, and are very intuitive. I, personally, am
currently 30, work professionally as a programmer/technician, and
run a BBS in Sioux City, IA. I also write many doors for the
excellent TriBBS Bulletin Board System by Mark Goodwin, and do
occasional contract programming. I strongly support the shareware
concept, and believe that if we completely removed all major
software companies from existence, the world would be a better
place...<grin>
You may contact me via:
FidoNet 1:288/24 (FREQ CFIND for latest version)
Internet craig.miller@f24.n288.z1.fidonet.org
BBS: Temples of Syrinx (712) 276-6219
Snail Mail: CraigerWare Enterprises
P.O. Bo 2672
Sioux City, IA 51106
Acknowledgements & Thanks-to List
─────────────────────────────────
Many thanks to the following companies or individuals for both
encouraging me to write quality software, and providing me with a
means to do so:
TSE ............. Semware Corporation ......... worlds best editor
TurboC .......... Borland International ....... worlds best compiler
Compaq .......... Compaq Computer Corporation . worlds best PC's
Trevor .......... My son ...................... letting me finish these
docs....<grin>
DeDe ............ My wife ..................... letting me finish the
program...<bigger grin>
PCC ............. Mark DeSmet ................. keeping me interested
enough in C to finally
learn it well
TurboC Bible .... The Waite Group ............. providing me with an
excellent reference
& tutorial
CFind Page 7
Revision History
────────────────
1.7 Removed chances made in v1.6, as the DIETing caused
occasional problems in DESQview.
1.6 Removed CRC self-check and started distributing DIETed
executables.
1.5 No changes. <g>
1.4 Visual enhancements.
1.3 Found a major bug in the searching algorithm. Fixed.
1.2 Found a bug in the command line parser, fixed.
Changed some of the recursing logic to make it slightly
faster, and more standardized. Also changed command
line parser to allow the '-' switch character in addition
to the '/' character.
1.1 Released hours after 1.0, modified to recursively search
hidden subdirectories, in addition to normal subdirs.
1.0 First public release.
CFind Page 8
Registration Form for CFind
───────────────────────────
Name ________________________________________
Address _____________________________________
City _____________________________________ State ____ Zip _________
Registered To: ___________________________________________
(This is for generating your key)
Your BBS number, if you would like key uploaded to you:
________________________________________
Your FIDOnet node address, if you would like the key crashmailed.
________________________________________
How did you hear about CFind? _______________________________________
_____________________________________________________________________
_____________________________________________________________________
What improvements would you make to the program or documentation?
_____________________________________________________________________
_____________________________________________________________________
_____________________________________________________________________
_____________________________________________________________________
Registration type: ______________________________________
Amount Enclosed: ______________________________________
Please feel free to return this form without any payment, should you
have any suggestions or improvements, and thank you for giving
CraigerWare a try!
Craig