home *** CD-ROM | disk | FTP | other *** search
/ ftp.whtech.com / ftp.whtech.com.tar / ftp.whtech.com / club100 / txt / zipsub.doc < prev   
Text File  |  2006-10-19  |  8KB  |  177 lines

  1.                            ZIPSUB.DOC
  2.                     (c)1989 Wilson Van Alst
  3.                       All rights reserved.
  4.  
  5.  
  6.   I. GENERAL DESCRIPTION
  7.  
  8.      A. ZIPSUB.CO is a machine language search & replace program that
  9.         lets you change selected strings in TEXT files very quickly.
  10.         Here are the main features:
  11.  
  12.         1. RAM files are searched and changed "in place" -- so you
  13.            never need the extra memory used by programs that make a
  14.            copy of the original file.
  15.  
  16.            a. The result is, you can work on very large files.
  17.  
  18.         2.  ZIPSUB runs in the AltLCD buffer, a 'protected' area of
  19.            computer memory where it should not conflict with other
  20.            machine language programs.  You do not have to CLEAR space
  21.            or change HIMEM to use AltLCD programs.
  22.  
  23.         3. You have an option, when you run ZIPSUB, of completely
  24.            automatic operation, or user-verification for each
  25.            replacement before it occurs.
  26.  
  27.            a. If you select verification, the program shows you each
  28.               original string, hightlighted in context, to help you
  29.               decide whether it should be replaced.
  30.  
  31.         4. The program makes it easy to perform several
  32.            search/replace operations on the same file, without
  33.            returning to the main MENU.
  34.  
  35.  II. OPERATION
  36.  
  37.      A. To run ZIPSUB.CO from the main MENU, just put the cursor over
  38.         the file and press <ENTER>.
  39.  
  40.      B. You'll see a screen listing all the RAM files and asking
  41.         which 'File?' you want to work on.
  42.  
  43.         1. Enter the name of a file, with or without a .DO extension
  44.  
  45.         2. If you enter a "null" at this point -- by pressing the
  46.            <ENTER> key without naming a file -- you'll return to the
  47.            computer menu.
  48.  
  49.            a. This is the normal way of exiting ZIPSUB
  50.  
  51.         3. If you enter an "illegal" file name, or the name of a file
  52.            that doesn't exist, you'll simply be asked for a new
  53.            entry.
  54.  
  55.      C. Once you've selected a file, ZIPSUB will clear the screen and
  56.         ask for a 'Find' string.
  57.  
  58.         1. Entering a "null" at this point will take you back to the
  59.            'File?' prompt, discussed above.
  60.  
  61.         2. Otherwise type in the text you want to replace in the
  62.            selected file.
  63.  
  64.            a. This entry may be up to 80 characters.
  65.  
  66.            b. You may search for any combination of alphabet
  67.               characters, numbers, graphics, spaces, and punctuation
  68.               marks
  69.               1) "control characters" are illegal -- except for TABs,
  70.                  which may be included at any point in the string,
  71.                  and count for just one character even though they
  72.                  may look like several spaces in a row
  73.  
  74.            c. For alphabet characters, it won't matter whether your
  75.               'Find' string is in upper or lower case
  76.               1) the program searches for all records containing your
  77.                  entry, regardless of case.
  78.  
  79.      D. After the 'Find?' entry, you'll be asked for a 'Sub?' string.
  80.  
  81.         1. In this instance, case =is= significant.  The 'Sub' string
  82.            is entered in the TEXT file exactly as you type it.
  83.  
  84.         2. If you enter a "null" for the 'Sub' string, it implies
  85.            that you want to delete the 'Find' string (i.e., replace
  86.            it with nothing).
  87.  
  88.            a. ZIPSUB will ask you to verify that this is what you
  89.               intend:
  90.               1) If you answer "Y" to the 'Delete?' prompt the
  91.                  program will go forward.
  92.               2) If you answer "N" or "Q", you'll return to the
  93.                  'Find?' prompt, giving you a chance to exit the
  94.                  program, or enter a new set of search and replace
  95.                  strings.
  96.  
  97.      E. The next prompt asks, simply, 'Ask?' -- and it wants to know
  98.         whether the upcoming search/replace operations should be done
  99.         automatically, or if you want to verify them one-at-a-time.
  100.  
  101.         1. If you enter "Q" (for "Quit") at this point, you'll return
  102.            to the 'Find?' prompt.
  103.  
  104.         2. If you respond "N" to the 'Ask?' inquiry, ZIPSUB will loop
  105.            through the file and make the requested changes without
  106.            intervention.
  107.  
  108.         3. If you answer "Y" to the 'Ask?' prompt, the program will
  109.            pause every time it finds a match for your 'Find' string
  110.            and ask whether you want to replace it.
  111.  
  112.            a. The 'Find' text is shown in context, highlighted by
  113.               reverse video, followed by a 'Y/N/Q' prompt:
  114.               1) "Y" makes the substitution and jumps to the next
  115.                  match for your 'Find' string;
  116.               2) "N" leaves the highlighted area unchanged and jumps
  117.                  to the next match;
  118.               3) "Q" abandons the current search/replace operation
  119.                  and takes you back to the 'Find?' prompt.
  120.  
  121. III. TECHNICAL NOTES
  122.  
  123.      A. Speed
  124.  
  125.         1. It's worth noting that ZIPSRT will work =very= quickly
  126.            when the size of the 'Sub' string exactly matches the size
  127.            of the 'Find' string.  In this case, the program only has
  128.            to make a one-for-one substitution inside the TEXT file.
  129.            When the string sizes are different, though, ZIPSRT has to
  130.            expand or contract the file to make things fit -- and it
  131.            takes a bit of time to move things around.  I think you'll
  132.            still be pleased with how fast the program runs.
  133.  
  134.      B. Selective searching
  135.  
  136.         1. It helps to use some imagination when you're using ZIPSUB
  137.            (or any other search/replace program).
  138.  
  139.               For example, if you wanted to change the word "cat" to
  140.            "feline" everywhere in a TEXT file, you might be tempted
  141.            just to type those words at the appropriate prompts and
  142.            let the program do its thing.  The problem is, you'd get
  143.            lots of strange looking results in words other than "cat"
  144.            that have the letters "c-a-t" in them.  Words like
  145.            "scatter" and "cathedral," would end up as "sfelineter"
  146.            and "felinehedral."
  147.  
  148.               However, if you answered the 'Find?' prompt with " cat
  149.            " (without the quotes), putting spaces before and after
  150.            the search word, you'd be sure to replace only stand-alone
  151.            "cat"s with your "feline"s.  (Of course, you'd miss spots
  152.            where "cat" was followed by a comma or period, or -- as in
  153.            this text -- sourrounded by quotation marks.  But you can
  154.            go back and do other quick S&Rs for " cat.", " cat," and
  155.            '"cat"' if you like.  As I said, it pays to use your
  156.            imagination.)
  157.  
  158.  IV. THANKS
  159.  
  160.      A. I'll never find adequate words to thank James Yi for writing
  161.         and sharing his machine language Assembler/ Disassembler/
  162.         Monitor program, ADSM.  He once said he'd take his "payback"
  163.         from others who use ADSM to write new software.  I'm tryin',
  164.         James, I'm tryin'.  Meantime, many thanks to Randy Hess, who
  165.         suggested several ways to improve ZIPSUB during its
  166.         development.
  167.  
  168.   V. SUPPORT
  169.  
  170.      A. I can be reached on CompuServe's M100 SIG if you have
  171.         questions or suggestions relating to ZIPSUB.  Please put your
  172.         correspondence on the SIG's message board, instead of sending
  173.         it via EasyPlex, because your comments may help another
  174.         reader get more out of the program.  Thanks.
  175.  
  176.         Wilson Van Alst [76576,2735]
  177.