home *** CD-ROM | disk | FTP | other *** search
/ Black Box 4 / BlackBox.cdr / dbase / btfl13.arj / BTFILER.DOC < prev    next >
Text File  |  1992-02-18  |  64KB  |  1,631 lines

  1.  
  2.  
  3.  
  4.  
  5.  
  6.  
  7.  
  8.  
  9.                                     BTFILER
  10.  
  11.  
  12.                 A Btrieve file recovery, viewing and editing utility
  13.                                   Version 1.30
  14.  
  15.  
  16.  
  17.  
  18.  
  19.  
  20.  
  21.  
  22.  
  23.  
  24.  
  25.  
  26.  
  27.  
  28.  
  29.  
  30.  
  31.  
  32.  
  33.                                         By
  34.  
  35.                               Access Microsystems Inc.
  36.                                 404 Midstreams Road
  37.                                Brick, NJ  08724-3838
  38.  
  39.                                   (908) 892-2683
  40.                                   CIS: 74040,607
  41.  
  42.  
  43.  
  44.  
  45.  
  46.                                  TABLE OF CONTENTS
  47.  
  48.      1.  Who made BTFILER?  Why?
  49.  
  50.      2.  What does BTFILER require?
  51.  
  52.      3.  What does BTFILER do?
  53.  
  54.         A. Intended actions
  55.         B. Unintended actions (dare we say BUGS?)
  56.  
  57.      4.  Details...
  58.  
  59.         A. Starting BTFILER
  60.         B. The Main Menu
  61.         C. The File Sub-menu
  62.  
  63.                 1. Browsing/Editing a BTRIEVE file
  64.  
  65.                         a. Moving around
  66.                         b. Editing a record
  67.                         c. Deleting a record
  68.                         d. Adding a record
  69.                         e. The File sub-menu in the Browse/Edit
  70.                               main menu
  71.                         f. The View sub-menu in the Browse/Edit
  72.                               main menu
  73.                         g. Special problems re: variable length
  74.                               records
  75.  
  76.                 2. Cloning a Btrieve file
  77.                 3. Packing a Btrieve file
  78.                 4. Test/Rebuild a Btrieve file
  79.  
  80.                         a. DOS Read test
  81.                         b. Index test
  82.                         c. Rebuild
  83.  
  84.                 5. Import/Export
  85.                 6. Misc. Btrieve Functions
  86.  
  87.                         a. Set Owner
  88.                         b. Clear Owner
  89.                         c. Statistics
  90.                         d. Btrieve Version
  91.                         e. Create file from BTB file
  92.                         f. Supplemental Index
  93.                         g. Transactions
  94.  
  95.                 7. Exiting BTFILER
  96.  
  97.         D. The Options Sub-menu
  98.  
  99.                 1. Set Colors
  100.                 2. Set Misc. Parameters
  101.                 3. Reset Btrieve
  102.                 4. REGISTER BTFILER
  103.  
  104.         E. The Help Sub-menu
  105.  
  106.                 1. List Error Codes
  107.                 2. List Operation Codes
  108.                 3. About BTFILER
  109.  
  110. 5.  Getting help/making suggestions/future directions
  111.  
  112.  
  113.  
  114. 1.  Who made BTFILER?  Why?
  115.  
  116.      BTFILER is a product of Access Microsystems Inc.  We do
  117.      programming in C and C++ under DOS and UNIX, often
  118.      using Btrieve as a file manager.  (If you have a
  119.      project we might be able to help with, contact us at
  120.      the phone or Compuserve number on the first page of the
  121.      documentation or throughout the software.)
  122.  
  123.      We have used several programs for looking at,
  124.      recovering data from, and editing Btrieve files.  We
  125.      have been disappointed by the results.  Some crashed,
  126.      others worked but punished us in the process.  We
  127.      thought that there must be a better way, and set out to
  128.      design such a product.  BTFILER is not quite that
  129.      product, but what we hope will be the first step in the
  130.      creation of a line of software for Btrieve users.  We
  131.      have ideas about automating the Btrieve file creation
  132.      process, allowing the import and export of comma
  133.      delimited files, as well as allowing editing in a user
  134.      friendly way (for instance, dates in mm/dd/yy format,
  135.      binary and packed information in ASCII form, etc.)
  136.  
  137.      We can't do all that just now, and so we made what we
  138.      consider a good first step.  If you become a registered
  139.      user, you can help us mold future products and future
  140.      updates to BTFILER.  Shareware works as a way to ensure
  141.      that you can try software before you buy only if you
  142.      support shareware authors.  If BTFILER meets a need,
  143.      please register!  Also, think about the possibility of
  144.      getting a distribution license and making BTFILER part
  145.      of your Btrieve application.
  146.  
  147.      DISCLAIMER - AGREEMENT
  148.  
  149.      Users of BTFILER must accept this disclaimer of
  150.      warranty:
  151.  
  152.      "BTFILER is supplied as is.  The author disclaims all
  153.      warranties, expressed or implied, including, without
  154.      limitation, the warranties of merchantability and of
  155.      fitness for any purpose. The author assumes no
  156.      liability for damages, direct or consequential, which
  157.      may result from the use of BTFILER."
  158.  
  159.      BTFILER is a "shareware program" and is provided at no
  160.      charge to the user for evaluation.  Feel free to share
  161.      it with your friends, but please do not give it away
  162.      altered or as part of another system.  The essence of
  163.      "user-supported" software is to provide personal
  164.      computer users with quality software without
  165.      high prices, and yet to provide incentive for
  166.      programmers to continue to develop new products.  If
  167.      you find this program useful and find that you are
  168.      using BTFILER and continue to use BTFILER after a
  169.      reasonable trial period, you must make a registration
  170.      payment of $29.00 to Access Microsystems Inc.  The
  171.      $29.00 registration fee will license one copy for use
  172.      on any one computer at any one time.  You must treat
  173.      this software just like a book.  An example is that this
  174.      software may be used by any number of people and may be
  175.      freely moved from one computer location to another, so
  176.      long as there is no possibility of it being used at one
  177.      location while it's being used at another.  Just as a
  178.      book cannot be read by two different persons at the same
  179.      time, a single copy of BTFILER cannot be used in two places
  180.      at once, unless the license is being violated.
  181.  
  182.      Commercial users of BTFILER must register and pay for
  183.      their copies of BTFILER within 30 days of first use or
  184.      their license is withdrawn.  Site-License arrangements
  185.      may be made by contacting Access Microsystems Inc. or
  186.      by filling out the registration form found in
  187.      REGISTER.DOC or produced by BTFILER.  See the
  188.      Options/Register BTFILER menu option.
  189.  
  190.      You are encouraged to pass a copy of BTFILER along to
  191.      your friends for evaluation.  Please encourage them to
  192.      register their copy if they find that they can use it.
  193.      All registered users will receive:
  194.  
  195.           A copy of the latest version of the BTFILER
  196.              system.
  197.           A printed manual.
  198.           Notice of future upgrades.
  199.           Information on future products.
  200.           A copy of our BU partial BUTIL replacement
  201.              program.  This program STOPs, RESETs Btrieve,
  202.              shows BTRIEVE version and CLONEs Btrieve files.
  203.              You may distribute this freely.
  204.  
  205.  
  206. 2.  What does BTFILER require?
  207.  
  208.         BTFILER requires:
  209.  
  210.           An IBM PC or compatible with 512 K (640K
  211.           recommended for large variable length records).
  212.  
  213.           MS/PC DOS version 2.0 or better.  Version 4.00 is
  214.           a known problem, so if you have a problem and you
  215.           have version 4.00 of MS/PC DOS, UPGRADE DOS FIRST!
  216.  
  217.           Btrieve version 4.0 or better.  Make sure to
  218.           tailor your Btrieve start-up parameters (See "Set
  219.           Misc. Parameters" in the File Sub-menu).
  220.  
  221.                 BTFILER also requires and is shipped with the
  222.                    following files:
  223.  
  224.                         BTFILER.DOC    This file
  225.  
  226.                         BTFILER.BER    A file with Btrieve Error
  227.                                           codes listed
  228.  
  229.                         BTFILER.BOP    A file with Btrieve Operation
  230.                                           codes
  231.  
  232.                         BTFILER.MNU    A Menu Control File
  233.  
  234.                         BTFILER.HLP    A Help file.
  235.  
  236.                         BTFILER.MSK    Formatting information -
  237.                                           PROPRIETARY FORMAT!
  238.  
  239.                         BTFILER.CF1    A configuration file
  240.  
  241.                         BTFILER.EXE    The executable file.  Run this
  242.                                        to use BTFILER.
  243.  
  244.                         REGISTER.DOC   A file with a BTFILER registration
  245.                                           form.  (Registration can be
  246.                                           printed by the program itself
  247.                                           as well.)
  248.  
  249.                         SAMPLE.BTB  A sample BTrieve Build file.  An ASCII
  250.                                           file used to describe a Btrieve
  251.                                           file to be created.
  252.  
  253.                         AMIMAP.EXE     A BONUS utility program that
  254.                                           lists the amount of memory
  255.                                           taken up by resident
  256.                                           programs like Btrieve
  257.  
  258.                         SAMPLE.BTB     A sample BTrieve Build ASCII
  259.                                           file, used to create Btrieve
  260.                                           Files (File/Misc. Btrieve
  261.                                           Functions/Create file from BTB).
  262.  
  263.                         SAMPLE.BTS     A sample BTrieve Supplemental
  264.                                           index ASCII file, used to
  265.                                           create a Supplemental Index.
  266.  
  267.                         BTCLONE.BAT    An example of a batch file that
  268.                                           takes parameters and builds a
  269.                                           keystroke file that is used to
  270.                                           automate a BTFILER operation,
  271.                                           in this case, CLONE.
  272.  
  273.                         BTRESET.BAT    An example of a batch file
  274.                                           that creates a keystroke
  275.                                           file to automate a simple BTFILER
  276.                                           operation, in this case, reset.
  277.                                           For further details on both
  278.                                           batch files, see Appendix B.
  279.  
  280.                 REGISTER.DOC  A file containing a
  281.                 registration form.
  282.  
  283.                 BTFILER may, from time to time, create the
  284.                 following files:
  285.  
  286.                        BTFILER.CF2    A second configuration file.
  287.  
  288.                        TMP?????.$$$   Temporary files created to
  289.                        save the state of the screen, etc. These may
  290.                        be deleted if you are SURE that no copy of
  291.                        BTFILER is running on the system or on a
  292.                        network the system is connected to.
  293.  
  294.                        CINSTALL.DAT   A Color configuration file.
  295.                        This file contains a single line of text.
  296.                        The line has 7 sets of 3 digit numbers, each
  297.                        3 digit number representing one of the types
  298.                        of colors used by BTFILER.  The file should
  299.                        look like this:
  300.  
  301.                                 rrrmmmooodddsssbbbnnn
  302.  
  303.                                 Where:
  304.  
  305.                                 rrr=decimal "regular" color.
  306.                                 mmm=decimal "menu" color.
  307.                                 ooo=decimal "selected menu option"
  308.                                             color.
  309.                                 ddd=decimal "active data entry field"
  310.                                             color.
  311.                                 aaa=decimal "status line" color.
  312.                                 bbb=decimal "box" color.
  313.                                 nnn="Hot" letter in menu option
  314.  
  315.  
  316. 3.  What does BTFILER do?
  317.  
  318.         A. Intended actions
  319.  
  320.           BTFILER allows you to TEST and RECOVER data from
  321.           Btrieve files.  In addition to standard sorts of
  322.           Btrieve testing (Test for consistent prev/next
  323.           links, etc.) BTFILER also has a DOS File test
  324.           which reads the entire file and reports if a DOS
  325.           Critical error (ABORT, RETRY or FAIL) error
  326.           occurs.
  327.  
  328.           BTFILER allows you to view, edit, search and
  329.           delete records in a Btrieve file.
  330.  
  331.           BTFILER allows you to Clone a Btrieve file (That
  332.           is, create an empty Btrieve file with the same key
  333.           structure and record size as the original).
  334.  
  335.           BTFILER allows you to Pack a Btrieve file (That
  336.           is, create a copy of a Btrieve file less the space
  337.           left by deleted records).
  338.  
  339.           BTFILER allows you to Import and Export records in
  340.           a straight ASCII format or a format like BUTIL,
  341.           Novell's Btrieve Developer's Utility.
  342.  
  343.           BTFILER allows you to create a Btrieve file with a
  344.           BTrieve Build file (.BTB) file and create a
  345.           supplemental index using a BTrieve Supplemental
  346.           (.BTS) file.  You may also DROP a supplemental
  347.           index.
  348.  
  349.           BTFILER allows you to begin and end transactions
  350.           within a single session, and will prompt you to
  351.           end the transaction if you try to do something
  352.           that can't be done in a transaction.
  353.  
  354.           BTFILER allows you to repeat repetitive tasks by
  355.           creating keystroke files that get passed back to
  356.           the keyboard buffer as the program is run.  This
  357.           also allows more technical users to provide easy
  358.           to use batch files for those less comfortable
  359.           operating BTFILER directly.  (See Appendix B).
  360.  
  361.           BTFILER allows you to Set and Clear owners of
  362.           Btrieve files, displays Btrieve version
  363.           information, and shows file statistics and key
  364.           structure.
  365.  
  366.           BTFILER lists Btrieve Error codes (arranged
  367.           numerically) and Operation codes (arranged
  368.           alphabetically).  You may also get details on
  369.           Btrieve error codes.
  370.  
  371.           BTFILER lets you choose from 4 different color
  372.           sets.
  373.  
  374.         B. Unintended actions (dare we say BUGS?)
  375.  
  376.           As of this writing date, there are no known bugs.
  377.           (Kind of reminds us of the compiler that reports,
  378.           after a successful compile, "None of the errors
  379.           were found").
  380.  
  381.           Previous versions had some problems displaying
  382.           Btrieve error codes, and problems in the display
  383.           some menus.  Previous versions also had minor
  384.           problems when you tried to Set Misc.
  385.           Parameters.  These problems have been cleared up.
  386.           Improvements in existing features include the
  387.           ability to edit records 256 bytes at a time.  The
  388.           HOME and END keys now work while viewing a Btrieve
  389.           file to move you to the first and last records
  390.           (respectively) in the file.  We have also improved
  391.           memory management.
  392.  
  393.           It is likely that VERY large variable length
  394.           records will cause problems with memory (but we
  395.           have not tested it with very large (>25K) variable
  396.           length records).  Please let us know if you run
  397.           across any problems.  See section 5, Getting
  398.           help/making suggestions.
  399.  
  400. 4.  Details...
  401.  
  402.      In the following sections, we detail actions required
  403.      to make BTFILER do work for you.  This assumes you have
  404.      placed the files mentioned above (What does BTFILER
  405.      require?) in your "PATH".
  406.  
  407.      For instance, if you type in PATH<Press ENTER> from the
  408.      DOS prompt (commonly "C:\>>") and you see the
  409.      following:
  410.  
  411.                 PATH=C:\;C:\DOS;C:\UTIL
  412.  
  413.      you should place the BTFILER file in the C:\, C:\DOS or
  414.      the C:\UTIL directory.  You must also have Btrieve
  415.      loaded, or if so configured, Btrieve or Brequest must
  416.      be available on the PATH.
  417.  
  418.         A. Starting BTFILER
  419.  
  420.           At any DOS prompt (or from the directory that
  421.           BTFILER files reside in, if not on your PATH)
  422.           type:
  423.  
  424.                 BTFILER<Press ENTER>
  425.  
  426.           If you wish to browse or edit a particular Btrieve
  427.           file, you may enter that on the command line as
  428.           well. For example:
  429.  
  430.                 BTFILER filename.ext<Press ENTER>
  431.  
  432.           BTFILER will then take a few seconds to load.
  433.           Depending upon the settings on the "Set Misc.
  434.           Parameters" screen (under the "Options" menu)
  435.           BTFILER may also load Btrieve or Brequest.  If you
  436.           get a message indicating that BTFILER is unable to
  437.           load Btrieve, load Btrieve from the command line
  438.           and then go to the "Set Misc. Parameters" screen
  439.           and ensure that the default Btrieve start up
  440.           parameters are set correctly.
  441.  
  442.           Two other command line parameters are possible.
  443.           /k:keyfile, where keyfile is the name of a file
  444.           with keystrokes for BTFILER to use on start-up.
  445.           See Appendix B for details on creation of a
  446.           keystroke file.  /c:myfile.cf2 where myfile.cf2 is
  447.           a version of the BTFILER.CF2 configuration file
  448.           created under Options/Set Misc. Parameters.  If
  449.           you need to, you can create 2 or more
  450.           configuration files, and with the /c command line
  451.           parameter, indicate which should be loaded.
  452.  
  453.           As BTFILER is loaded a screen will appear briefly
  454.           to list the registered owner of this copy of
  455.           BTFILER (Thank You!) or to remind you that you are
  456.           currently using an unregistered copy.  This screen
  457.           will remain on the screen for a few seconds, and
  458.           then you may press any key to continue.  Note that
  459.           the status line (the bottom line on the screen)
  460.           will almost always tell you what BTFILER is doing
  461.           or what you should do next.
  462.  
  463.         B. The Main Menu
  464.  
  465.           The Main Menu is a menu bar running across the top
  466.           of the screen.  This menu has three options:
  467.           File, Options, and Help.
  468.  
  469.           You can maneuver around the menu by using arrow
  470.           keys and the ENTER key, as well as ALT-Letter
  471.           combinations. (For instance, if no sub-menu is
  472.           "dropped," you may press the ALT and the H key to
  473.           get to the Help sub-menu.
  474.  
  475.           To exit BTFILER, you can press ESC (or press ESC
  476.           twice if a sub-menu is "dropped") and you will
  477.           return to DOS. You may also exit by pressing ENTER
  478.           while the Exit option of the File sub-menu is
  479.           highlighted.
  480.  
  481.         C. The File Sub-menu
  482.  
  483.           The File sub-menu includes four options:
  484.           Browse/Edit Btrieve File, Clone Btrieve File, Pack
  485.           Btrieve File,and Exit.
  486.  
  487.           1. Browsing/Editing a BTRIEVE file
  488.  
  489.                When ENTER is pressed (or ALT-B is pressed)
  490.                in the File sub-menu, you will be prompted to
  491.                enter a file name.  The default is "*.DAT"
  492.                If you supplied a file name on the command
  493.                line when starting BTFILER, or if you have
  494.                already browsed/edited a Btrieve file, that
  495.                will be the default.  If you press ENTER with
  496.                a filename containing '?' or '*' (an
  497.                "ambiguous" file name) BTFILER will present
  498.                you with a menu of files like the file name
  499.                entered.  If the menu is presented, use the
  500.                arrow keys to get to the correct file and
  501.                press ENTER.  You may also press ESC and re-
  502.                enter the file name.  If you press ESC while
  503.                entering the file name, you will return to
  504.                the menu.
  505.  
  506.                Once the Btrieve file selected is opened and
  507.                some of the records are loaded, you will be
  508.                presented with a screen with three parts:
  509.  
  510.                 The Browse/Edit Main Menu bar
  511.                 The Scale
  512.                 The Data area.
  513.  
  514.                The Browse/Edit Main Menu bar works very much
  515.                like the main menu described earlier.  One
  516.                difference is that the menu here is not the
  517.                focus of activity. When you start
  518.                browsing/editing a file, no options on the
  519.                Browse/Edit Main Menu are highlighted.  The
  520.                focus is on the data below.  To get to the
  521.                Browse/Edit Main Menu, simply press ALT and F
  522.                (to get to the File sub-menu) or ALT and V
  523.                (to get to the View sub-menu).
  524.  
  525.                The Scale lets you know what offset within
  526.                the record you are looking at.  The right and
  527.                left arrows will move you 10 positions to the
  528.                left or right.
  529.  
  530.                The Data area of the screen is a straight
  531.                listing of the data in the records in the
  532.                file.  Note that there may be some strange
  533.                characters on the screen.  This is perfectly
  534.                normal if the Btrieve file contains binary or
  535.                packed data.
  536.  
  537.                   a. Moving around
  538.  
  539.                     Use the arrow keys and the Page-up and
  540.                     Page-down keys to move around.  When you
  541.                     enter the screen, the top line will be
  542.                     highlighted.  Use the down arrow to
  543.                     highlight another record, and use the
  544.                     left and right arrows to view the rest
  545.                     of a record that is larger than 80
  546.                     characters.
  547.  
  548.                   b. Editing a record
  549.  
  550.                     To edit a Btrieve record, use the arrow
  551.                     keys to highlight the record you wish to
  552.                     edit and press ENTER.  You will be
  553.                     presented with a menu asking if you want
  554.                     to Edit this record, Delete this record,
  555.                     Add a record like this one, or Continue
  556.                     Browsing. With Edit this record
  557.                     highlighted, press ENTER.
  558.  
  559.                     You will be presented with a window on
  560.                     the screen that will allow you to edit,
  561.                     256 characters at a time, the record
  562.                     that was selected.  By default you will
  563.                     be doing a HEX edit.  To switch back and
  564.                     forth between HEX and ASCII editing,
  565.                     press the TAB key.  Use the cursor
  566.                     movement keys to move around the data.
  567.  
  568.                     To exit the editing screen, press ESC.
  569.                     If you make changes, a Yes or No box
  570.                     will appear reminding you that the data
  571.                     was changed, and asking if you wish to
  572.                     save changes.  Press 'Y' to save
  573.                     changes, or 'N' to abandon.  It is
  574.                     possible to make changes that Btrieve
  575.                     won't allow (creating a duplicate record
  576.                     in a key that does not allow duplicates
  577.                     or trying to modify a non-modifiable
  578.                     key) and if you do that you will get an
  579.                     error message.
  580.  
  581.                   c. Deleting a record
  582.  
  583.                     To delete a Btrieve record, use the
  584.                     arrow keys to highlight the record you
  585.                     wish to delete and press ENTER.  You
  586.                     will be presented with a menu asking if
  587.                     you want to Edit this record, Delete
  588.                     this record, Add a record like this one
  589.                     or Continue Browsing.  With Delete this
  590.                     record highlighted, press ENTER.
  591.  
  592.                     You will be asked if you are sure you
  593.                     want to delete the record.  Press 'Y' to
  594.                     delete it, or 'N' to not delete the
  595.                     record
  596.  
  597.                   d. Adding a record like the current record
  598.  
  599.                     To add a Btrieve like the record you are
  600.                     currently editing (using an existing record as
  601.                     a model ), use the arrow keys to highlight the
  602.                     record most like the one you wish to add and
  603.                     press ENTER. You will be presented with a
  604.                     menu asking if you want to Edit this record,
  605.                     Delete this record, Add a record like this
  606.                     record, or Continue Browsing.  With Add
  607.                     a record like this record highlighted,
  608.                     press ENTER.
  609.  
  610.                     You will be presented with a screen very
  611.                     much like the editing screen.  Make
  612.                     whatever changes you wish.  When you are
  613.                     done, press ESC.  You then will be asked
  614.                     if you wish to save the changes.  Press
  615.                     'Y' to save the new record, or 'N' to
  616.                     abandon the changes.  It is possible to
  617.                     try to add a new record that Btrieve
  618.                     won't allow (creating a duplicate record
  619.                     in a key that does not allow duplicates)
  620.                     and if you do that you will get an error
  621.                     message.
  622.  
  623.                   e. The File sub-menu in the Browse/Edit main menu
  624.  
  625.                     This menu allows you to select a new
  626.                     file or exit to the Main Menu.  To get
  627.                     to the Files sub-menu in the Browse/Edit
  628.                     main menu while browsing data, press the
  629.                     ALT and F keys.
  630.  
  631.                   f. The View sub-menu in the Browse/Edit main menu
  632.  
  633.                     To get to the View sub-menu in the
  634.                     Browse/Edit main menu while browsing
  635.                     data,press the ALT and V keys.  The View
  636.                     sub-menu in the Browse/Edit main menu
  637.                     has four options:  Key Only, Set Key
  638.                     Number, Begin View With, and Search.
  639.  
  640.                     Key Only allows you to switch from
  641.                     viewing the entire record to a key only
  642.                     browse.  To use the check-box, press the
  643.                     space bar and a check mark will appear
  644.                     and disappear.  If the check mark
  645.                     appears when ENTER is pressed, only the
  646.                     key will be displayed.
  647.  
  648.                     Set Key Number allows you to set the
  649.                     order you wish to view the data.  The
  650.                     field where you enter the key number
  651.                     will default to the current key number.
  652.  
  653.                     Begin View With allows you to jump to a
  654.                     particular key value in the file.
  655.  
  656.                     Search allows you to search out a record
  657.                     in the file looking for a particular
  658.                     string of text.  The search can be
  659.                     global or starting from the top line on
  660.                     the screen, and it can be case sensitive
  661.                     or insensitive to the case of the
  662.                     characters entered (upper an lowercase
  663.                     treated the same).  If the string is
  664.                     found, the first record with the string
  665.                     will be displayed with the matching text
  666.                     flashing.
  667.  
  668.                   g. Special problems with Variable length records.
  669.  
  670.                     Variable length records present a
  671.                     special problem when building a generic
  672.                     Btrieve file viewer.  The only limit to
  673.                     the size of a Btrieve variable length
  674.                     record is 64K.  Most Variable length
  675.                     records are MUCH shorter.  If you work
  676.                     with variable length records, please
  677.                     make sure you set your "Largest variable
  678.                     record" under "Set Misc. Parameters"
  679.                     under "Options" on the Main Menu to a
  680.                     value bigger than any record you might
  681.                     expect to read in
  682.  
  683.                     If you edit a variable length record, it
  684.                     will be written back at the same length.
  685.  
  686.           2. Cloning a Btrieve file
  687.  
  688.                With this option, you can make an empty copy
  689.                of an existing Btrieve file.  You must enter
  690.                the name of the Btrieve file as well as the
  691.                name of the "clone" file to be created.
  692.  
  693.           3. Packing a Btrieve file
  694.  
  695.                Like most DOS files, Btrieve files get bigger
  696.                as records are added, but do not shrink as
  697.                records are deleted.  This can be especially
  698.                noticeable if you have a transaction file
  699.                that grows and grows until some month or year
  700.                end procedure, and then is purged.  The space
  701.                where the deleted records were is still in
  702.                the file.  This space will eventually be used
  703.                again, but what if you can't wait?
  704.  
  705.                That is where Packing comes in.  Simply
  706.                supply the name of the file to be packed, and
  707.                BTFILER will rewrite it without the space
  708.                where the deleted records were.  The original
  709.                file is saved with an extension of .BAK.
  710.                Please ensure that the packed file is good
  711.                and then you may delete the .BAK.
  712.  
  713.           4. Test/Rebuild a Btrieve file
  714.  
  715.                This menu allows you to test a Btrieve file
  716.                to ensure that DOS can read the entire file
  717.                without a DOS Critical error (Abort, Retry,
  718.                Fail...), tests that all indices (keys) of a
  719.                Btrieve file are correctly linked, and allows
  720.                you to rebuild a damaged file.  The
  721.                explanations for these options follows.
  722.  
  723.                   a. DOS Read Test
  724.  
  725.                     This option allows you to test a file to
  726.                     ensure that DOS can read through the
  727.                     entire file.  The file in question need
  728.                     not even be a Btrieve file.
  729.  
  730.                   b. Index Testing
  731.  
  732.                     This option tests a Btrieve file to
  733.                     ensure that the links in the file (in
  734.                     both directions for each key) are
  735.                     correct.  A record could be written to
  736.                     disk in such a way that it points to
  737.                     itself, or to some other record that is
  738.                     not the correct record.  This test will
  739.                     look for such problems.
  740.  
  741.                   c. Rebuild
  742.  
  743.                     If you don't normally read
  744.                     documentation, PLEASE READ THIS!  This
  745.                     is a "last resort" procedure that should
  746.                     be used only if no recent backup exists.
  747.                     While there is little chance of damage
  748.                     occurring to your Btrieve file since the
  749.                     original is opened in read-only mode,
  750.                     and the original is saved as a .BAK
  751.                     file, backups are the best bet!  There
  752.                     is no guarantee that this procedure will
  753.                     get all records, although it is likely
  754.                     that almost all records will be
  755.                     recovered.
  756.  
  757.                     This procedure uses physical positioning
  758.                     (not logical positioning, going through
  759.                     the file via a key) to read from the
  760.                     first physical record to the last.  If
  761.                     an error occurs while proceeding from
  762.                     beginning to end, the program tries to
  763.                     step directly to the last record, and
  764.                     tries to read from end to beginning.  If
  765.                     there is only one record that has a
  766.                     problem, all but that one record should
  767.                     be recovered.
  768.  
  769.          5. Import/Export
  770.  
  771.                Select Import/Export from the File menu under
  772.                the Main Menu and you will be presented with
  773.                a menu that allows you to import or export
  774.                records to or from a Btrieve file.  Upon
  775.                selecting Import or Export. you will be
  776.                presented with a screen that allows you to
  777.                specify the Source and Destination file.  You
  778.                will also be allowed to choose between a
  779.                BUTIL style ASCII file or a straight ASCII
  780.                file, without the length specifier required
  781.                by BUTIL.  If you choose to NOT use the
  782.                BUTIL format, the file in question should be
  783.                a fixed length record with NO binary data.
  784.                The length of the record for ASCII files not
  785.                in the BUTIL style is the number of bytes
  786.                until the ASCII CR/LF characters are found.
  787.                In a binary file, it is possible that these
  788.                characters might naturally occur, causing
  789.                BTFILER to think that the record ends in
  790.                the middle of a field of binary data.  This is
  791.                clearly not a good thing.
  792.  
  793.                The format of the BUTIL style ASCII file is
  794.                as follows:
  795.  
  796.                 29,this is a 29 character record<CR/LF>
  797.  
  798.                That is, each record should contain the
  799.                decimal length followed by a comma, followed
  800.                by the record, padded with spaces if needed
  801.                to make it the length specified, followed by
  802.                CR/LF (hex 0D0A).
  803.  
  804.  
  805.          6. Misc. Btrieve Functions
  806.  
  807.                   a. Set Owner
  808.  
  809.                     Btrieve allows users to set "owners" for
  810.                     files.  By setting an "owner," a Btrieve
  811.                     user can choose to allow no access to
  812.                     the file without the owner name or allow
  813.                     read-only access, and the user can
  814.                     choose whether the file will be
  815.                     encrypted or not.  It is important to
  816.                     remember that if you set an owner for a
  817.                     Btrieve file, any program that is to
  818.                     access it (including BTFILER) must know
  819.                     that user name, and the user must
  820.                     remember the user name if s/he wishes to
  821.                     Clear the owner (see below).
  822.  
  823.                     When the File/Misc. Btrieve
  824.                     Functions/Set Owner menu option is
  825.                     selected, BTFILER displays a box with
  826.                     three fields.  In the first field, enter
  827.                     the name of the file for which an owner
  828.                     name is to be set.  In the second field,
  829.                     enter the string that will become the
  830.                     new "owner."  In the third field you
  831.                     will be presented with a menu that will
  832.                     allow you to choose whether or not to
  833.                     allow read-only access without the owner
  834.                     name, and whether or not the Btrieve
  835.                     file should be encrypted.  Highlight the
  836.                     appropriate option and press ENTER.  If
  837.                     you have selected an option that calls
  838.                     for encryption, some time may be
  839.                     required.  Please be patient.
  840.  
  841.                   b. Clear owner
  842.  
  843.                     When the File/Misc. Btrieve
  844.                     Functions/Clear Owner menu option is
  845.                     selected, BTFILER displays a box with
  846.                     two fields.  In the first field, enter
  847.                     the name of the file for which an owner
  848.                     name is to be cleared.  In the second
  849.                     field, enter the current "owner."  If
  850.                     you have selected a Btrieve file that
  851.                     had an owner name set with encryption,
  852.                     some time may be required.  Please be
  853.                     patient.
  854.  
  855.                   c. Statistics
  856.  
  857.                     When the File/Misc. Btrieve
  858.                     Functions/Statistics menu option is
  859.                     selected, BTFILER prompts for a file
  860.                     name to be entered.  If the file name
  861.                     entered exists and is a valid Btrieve
  862.                     file, BTFILER will display information
  863.                     about the file, including the number of
  864.                     records and number of keys, the record
  865.                     length, the file length, and some
  866.                     information on the actual space used, on
  867.                     average, for each record in the file and
  868.                     the % utilization.  Information on the
  869.                     keys will appear in a box on the lower
  870.                     portion of the screen.  If more keys
  871.                     than will fit on one screen are present,
  872.                     use the arrow or page down keys to see
  873.                     the rest of the key information.
  874.  
  875.                   d. Btrieve Version
  876.  
  877.                     When the File/Misc. Btrieve
  878.                     Functions/Btrieve Version menu option is
  879.                     selected, BTFILER displays a small box
  880.                     that gives Btrieve version information,
  881.                     for instance "Btrieve Version 5.10 for
  882.                     Networks."  Press any key to continue.
  883.  
  884.                   e. Create file from BTB file
  885.  
  886.                      Select this option to create a new Btrieve file.
  887.                      You will need to supply the name of a
  888.                      BTrieve Build file (BTB) and a name for the
  889.                      new file.  This option is similar to  BUTIL's
  890.                      -CREATE option, but with much better error
  891.                      handling.  Please see the sample BTB file
  892.                      called SAMPLE.BTB provided with BTFILER
  893.                      system and listed in Appendix A.
  894.  
  895.                   f. Supplemental Index
  896.  
  897.                      Selecting this menu option will give you
  898.                      another menu, where you may create or
  899.                      drop a supplemental index.  You must
  900.                      have a .BTS file (see SAMPLE.BTS for a
  901.                      sample of the format).  Enter the .BTS
  902.                      file name in the first field, and the
  903.                      name of the Btrieve file to add the
  904.                      supplemental index to in the next.
  905.  
  906.                      If you choose to drop a supplemental
  907.                      index, you will be asked to supply the
  908.                      Btrieve file name and the index number
  909.                      to drop.  Use File/Misc. Btrieve
  910.                      Functions/Statistics to determine the
  911.                      key number to drop.
  912.  
  913.                   g. Transactions
  914.  
  915.                      You may begin a transaction, or if one
  916.                      is already in progress, end a
  917.                      transaction using this menu option.
  918.                      When ending a transaction, you may
  919.                      choose to simply end the transaction
  920.                      (changes saved) or you may abandon the
  921.                      transaction (changes lost).
  922.  
  923.          7. Exiting BTFILER
  924.  
  925.                Choose this option to exit BTFILER and return
  926.                to DOS.  You may also exit by pressing ESC
  927.                (or by pressing ESC twice if you are in the
  928.                File, Options, or Help sub-menu).
  929.  
  930.  
  931.        D. The Options Sub-menu
  932.  
  933.          1. Set Colors
  934.  
  935.                Choose from the four color sets mentioned.
  936.  
  937.          2. Set Misc. Parameters
  938.  
  939.                Choose this option and you will be presented
  940.                with a screen that looks like this:
  941.  
  942.                   Set BTFILER Misc. Options
  943.  
  944.                               [_] Load Btrieve?
  945.                               [_] Load Brequest?
  946.  
  947.         Browse/Edit Open Mode: ___________
  948.  
  949.          Btrieve load options: ________________________
  950.  
  951.         Brequest load options: ________________________
  952.  
  953.    Memory to save for Btrieve: ______
  954.  
  955.        Owner name for Btrieve: ____________________
  956.  
  957.       Largest variable record: _____
  958.  
  959.   Print report to (LPT1, etc): ________________________
  960.  
  961.       Default File Name Mask: _____________________________
  962.            (i.e. "*.DAT")
  963.  
  964.                The first two questions ask if you would like
  965.                to load Btrieve and/or Brequest.  It might be
  966.                better (from a memory control standpoint) to
  967.                have Btrieve loaded BEFORE you run BTFILER,
  968.                but it is often convenient to allow BTFILER
  969.                to load it for you.
  970.  
  971.                The next question allows you to determine the
  972.                open mode when files are browsed or edited
  973.                (using the File/Browse-Edit Btrieve File menu
  974.                option).  If you wish to ensure that the file
  975.                is not changed, set Read-Only.  If working on
  976.                a network, and you wish to have exclusive
  977.                access to a file, set Exclusive.  To verify
  978.                data as it is written (normally not needed
  979.                and not very effective in any case) set
  980.                Verify.  If you are working on a file where
  981.                you are starting fresh and have nothing to
  982.                lose, you may want to set Accelerated.  Note
  983.                that Accelerated has no effect on speed of
  984.                reading the file, and will leave your file
  985.                damaged if it is not closed properly.  This
  986.                option is included for completeness, not
  987.                because we recommend this option.  All
  988.                options are presented to you on a menu.
  989.  
  990.                The next two questions allow you to specify
  991.                Btrieve and/or Brequest start-up (load)
  992.                options. Please see your Btrieve or Brequest
  993.                manual for specifics.  Also, note that it is
  994.                possible to give invalid load options to
  995.                Btrieve that will prevent Btrieve from being
  996.                loaded.  In that case, load Btrieve BEFORE
  997.                you enter BTFILER and then correct the
  998.                Btrieve load options.
  999.  
  1000.                The amount of memory to save for Btrieve is
  1001.                dependent upon the version of Btrieve you are
  1002.                using, the load options you specify, and the
  1003.                availability of extended (or is that
  1004.                expanded...) memory.  Run Btrieve with the
  1005.                load parameters you expect to use and then
  1006.                run AMIMAP.EXE (a utility that reports on the
  1007.                space taken up by resident programs) and note
  1008.                how much space is taken up by Btrieve.  Add
  1009.                several thousand bytes to this for good luck,
  1010.                and this will reserve enough memory for
  1011.                Btrieve.  130000 is a safe number to use if
  1012.                this is too much for you to figure out.
  1013.  
  1014.                Owner name is the owner name to use when
  1015.                opening up Btrieve files that require an
  1016.                owner name.  If you don't know what this
  1017.                means, you probably don't need to fill this
  1018.                in.
  1019.  
  1020.                Largest variable record is important if you
  1021.                are going to read variable length record
  1022.                Btrieve files.  If you have too small a
  1023.                number here, you might get an error 22
  1024.                (buffer too short).  If you have too large a
  1025.                number here, you may have memory problems.
  1026.  
  1027.                Print report to specifies where reports
  1028.                (currently only the registration form and printing
  1029.                this documentation) should print.  This should
  1030.                almost always be LPT1 or PRN.  Try those if
  1031.                in doubt.
  1032.  
  1033.                The default file mask allows you to set the
  1034.                default file mask without having to enter it
  1035.                on the command line each time.  The default
  1036.                is "*.DAT", but for many "*.BTR" is more
  1037.                convenient.
  1038.  
  1039.          3. Reset Btrieve
  1040.  
  1041.                Issues a RESET command to Btreive.
  1042.  
  1043.          4. REGISTER BTFILER
  1044.  
  1045.                If you like what you see, and would like to
  1046.                make sure that shareware programs like
  1047.                BTFILER are produced, you must
  1048.                register and pay for the use of the program.
  1049.                The $29.00 requested (for a single copy) is a
  1050.                steal, and to further entice you, we even
  1051.                made up this neat utility to print out the
  1052.                registration form for you.  Simply fill in
  1053.                the requested information and the form will
  1054.                be printed.  Fill in the number of single
  1055.                user or site licenses, the size disks you
  1056.                wish to receive,and mail it to the address on
  1057.                the form.  You can always just jot down your
  1058.                name and address and mail that in with a
  1059.                notation that you are registering for
  1060.                BTFILER, but what the heck, that's what
  1061.                computers are for!
  1062.  
  1063.                If you need to use a credit card, you may
  1064.                register on-line on CompuServe.  Type GO SE at
  1065.                any prompt and you will go to Software
  1066.                Excitement's connect-charge free section.  Choose
  1067.                menu option 7 (*** Register Shareware Software
  1068.                ***), then option 2 (Order by Product Title).
  1069.                BTFILER will be listed on the first page or two.
  1070.                Enter the number to the left of BTFILER and
  1071.                supply the requested information.  Credit card
  1072.                orders may also be placed by phone at
  1073.                (1-800-444-5457).  If you have any questions
  1074.                ordering, please contact us at the phone number
  1075.                or CIS ID listed throughout the documentation and
  1076.                the program.
  1077.  
  1078.                If you register, you will get:
  1079.  
  1080.                         A copy of the latest version of the
  1081.                            BTFILER system.
  1082.                         A printed manual.
  1083.                         Notice of future upgrades.
  1084.                         Information on future products.
  1085.                         A copy of our BU partial BUTIL
  1086.                            replacement program.
  1087.                            This program STOPs, RESETs Btrieve,
  1088.                            shows BTRIEVE version and CLONEs
  1089.                            Btrieve files.  You may distribute
  1090.                            this freely.
  1091.  
  1092.  
  1093.  
  1094.        E. The Help Sub-menu
  1095.  
  1096.          These options are self explanatory (and non-
  1097.          threatening if you just try them out).
  1098.  
  1099.          1. List Error Codes
  1100.  
  1101.          2. List Operation Codes
  1102.  
  1103.          3. About BTFILER
  1104.  
  1105. 5.  Getting help/making suggestions/future directions
  1106.  
  1107.      If you are a registered user, or if you are having a
  1108.      problem getting started, PLEASE contact us at:
  1109.  
  1110.                         Access Microsystems Inc.
  1111.                         404 Midstreams Road
  1112.                         Brick, NJ  08724-3838
  1113.  
  1114.                         (908) 892-2683
  1115.                         CIS: 74040,607
  1116.  
  1117.      We generally work 9 to 5, Monday through Friday.  We
  1118.      may not always be here when you call, but we will try
  1119.      to return calls if you leave a SPECIFIC message.  We
  1120.      monitor Compuserve (CIS) messages daily for support
  1121.      purposes, but understand that not everyone is ready for
  1122.      E-Mail.
  1123.  
  1124.      We seek your advice on future directions for this and
  1125.      other products.  We expect (if the interest in BTFILER
  1126.      warrants) a follow-on product that will add some more
  1127.      advanced editing, as well as more powerful utilities
  1128.      for doing things like importing and exporting data and
  1129.      creating files.  We would love your advice.
  1130.  
  1131.  
  1132.  
  1133.  
  1134.                   APPENDIX A - Listing of SAMPLE.BTB
  1135.  
  1136. The following is a listing of SAMPLE.BTB, An ASCII file that
  1137. describes a BTRIEVE file to be built with BTFILER's
  1138. File/Misc. Btrieve Functions/Create File from BTB file menu
  1139. option.  Please modify this file to create the type of file
  1140. YOU need.  Keep the BTB file you create on line to rebuild
  1141. the file you create as needed.
  1142.  
  1143. #
  1144. #       This line (and all lines beginning with '#') are COMMENTS.
  1145. #
  1146. #       This is a sample BTrieve Build (BTB) file.  It allows for the
  1147. #       creation of Btrieve files in BTFILER.  It does the same thing
  1148. #       as the BUTIL -CREATE function, but with one significant
  1149. #       difference:  Error diagnostics are clearer.  This removes (I
  1150. #       think) the most significant problem with the BUTIL -CREATE
  1151. #       process.  Someday an interactive create utility will be part
  1152. #       of BTFILER, but until then, this will have to do...
  1153. #
  1154. #       Case is not important, and some fields are optional (as
  1155. #       noted in comments).
  1156. #
  1157. #       These are the fields possible listed in order of appearance
  1158. #       in the file level settings section:
  1159. #
  1160. #               RECORD LEN=n
  1161. #               PAGE SIZE=n, multiple of 512
  1162. #               VARIABLE=<YES or NO>
  1163. #               BLANK TRUNCATION=<YES or NO>      OPTIONAL!
  1164. #               DATA COMPRESSION=<YES or NO>
  1165. #               FREE SPACE THRESHOLD=<10, 20 or 30>
  1166. #               ALTERNATE FILE=<filename>         OPTIONAL if no alternate key
  1167. #               INCLUDE DATA=<YES or NO>          OPTIONAL!
  1168. #               NUMBER OF KEYS=n
  1169. #
  1170. #
  1171. # These are file level settings, with more details...
  1172. #
  1173. RECORD LEN=131
  1174. #
  1175. # In the Help menu, see "Calculate Page Size" to find optimal size.
  1176. #
  1177. PAGE SIZE=1536
  1178. VARIABLE=NO
  1179. #
  1180. # BLANK TRUNCATION is only meaningful with variable length
  1181. #       records, so this BLANK TRUNCATION= line is optional.
  1182. #
  1183. BLANK TRUNCATION=NO
  1184. DATA COMPRESSION=NO
  1185. #
  1186. # FREE SPACE THRESHOLD=n, where 'n' is 10, 20 or 30 ONLY!
  1187. #
  1188. FREE SPACE THRESHOLD=20
  1189. #
  1190. #  ALTERNATE FILE=fname, where fname is the name of a file like
  1191. #         UPPER.ALT.  This line is optional IF no ALTERNATE=YES
  1192. #         key segments exist.
  1193. #
  1194. ALTERNATE FILE=UPPER.ALT
  1195. #
  1196. #  INCLUDE DATA=<Y or N> is used to determine if the file is key only
  1197. #        Data only, or key and data.  INCLUDE DATA= line is OPTIONAL!
  1198. #
  1199. #  For KEY ONLY:   INCLUDE DATA=NO
  1200. #                  NUMBER OF KEYS=1
  1201. #  and key length is == to record length.
  1202. #
  1203. #  For DATA ONLY:  INCLUDE DATA=YES
  1204. #                  NUMBER OF KEYS=0
  1205. #
  1206. INCLUDE DATA=Yes
  1207. #
  1208. #  NUMBER OF KEYS= is used as a cross check of the segments
  1209. #       passed below.  In case of a conflict, the option is given
  1210. #       to accept the key count reflected in the segments, or
  1211. #       abandoning creation of the file.
  1212. #
  1213. NUMBER OF KEYS=2
  1214. #
  1215. #  END OF FILE LEVEL SETTINGS!
  1216. #
  1217. #  This marks the beginning of key segment level information.
  1218. #       If I were you, and I were creating BTB files, I would
  1219. #       place a large comment band between each key segment
  1220. #       to remind myself what I think I am doing.  Just a
  1221. #       thought...
  1222. #
  1223. #  The lines for each key segment are in the following order:
  1224. #
  1225. #       START=n, where 'n' is the starting position of the key
  1226. #       LEN=n, where 'n' is the length of the key
  1227. #       MODIFIABLE=s, where 's' is Y or N (or YES or NO or Yes or...)
  1228. #                        Allows Modifications to be made to the key?
  1229. #       DUPLICATES=s, ditto above...Allows Duplicate keys?
  1230. #       ALTERNATE=s, where 's' is as above.  Alternate Collating Sequence?
  1231. #       DESCENDING=s, like above.  Sorts Hi to Lo?
  1232. #       TYPE=t, where 't' is EXACTLY one (case difference OK) of the following:
  1233. #
  1234. #               "String",
  1235. #               "Integer",
  1236. #               "Float",
  1237. #               "Date",
  1238. #               "Time",
  1239. #               "Decimal",
  1240. #               "Money",
  1241. #               "Logical",
  1242. #               "Numeric",
  1243. #               "Bfloat",
  1244. #               "Lstring",
  1245. #               "Zstring",
  1246. #               "Unsigned Binary",
  1247. #               "Autoincrement",
  1248. #
  1249. #       NULL=n, where 'n' is the decimal NULL value (commonly 0 or 32) OR
  1250. #                  NULL=N/A to explicitly state no NULL value.
  1251. #                  NULL= is OPTIONAL.
  1252. #       SEGMENT=s, where 's' is Y or N (or Yes or N0...).  The number of
  1253. #                  segments with a SEGMENT=No value should be the same
  1254. #                  as the number of keys you declare.
  1255. #
  1256. #
  1257. #  Key 0/Segment 1
  1258. #
  1259. START=1
  1260. LEN=11
  1261. MODIFIABLE=n
  1262. DUPLICATES=n
  1263. ALTERNATE=n
  1264. DESCENDING=n
  1265. TYPE=STRING
  1266. NULL=N/A
  1267. SEGMENT=NO
  1268. #
  1269. #  key 1/segment 1
  1270. #
  1271. START=12
  1272. LEN=30
  1273. MODIFIABLE=y
  1274. DUPLICATES=y
  1275. ALTERNATE=y
  1276. DESCENDING=n
  1277. TYPE=STRING
  1278. NULL=N/A
  1279. SEGMENT=YES
  1280. #
  1281. #  key 1/segment 2
  1282. #
  1283. START=1
  1284. LEN=11
  1285. MODIFIABLE=y
  1286. DUPLICATES=y
  1287. ALTERNATE=y
  1288. DESCENDING=n
  1289. TYPE=STRING
  1290. NULL=N/A
  1291. SEGMENT=NO
  1292. #
  1293. #  That's all, folks!
  1294. #
  1295.       Appendix A - Listing of SAMPLE.BTB and SAMPLE.BTS
  1296.  
  1297.  
  1298. Use the following file (supplied on disk as well) that
  1299. allows you to create a Btrieve file by describing it in an
  1300. ASCII file.  Modify it for your needs and run the
  1301. File/Misc. Btrieve Functions/Create file using BTB file menu
  1302. option.  When asked, supply the name of the BTB file you
  1303. have modified for your use, or use the SAMPLE.BTB file to
  1304. see how the system works.
  1305.  
  1306. #
  1307. #       This line (and all lines beginning with '#') are COMMENTS.
  1308. #
  1309. #       This is a sample BTrieve Build (BTB) file.  It allows for the
  1310. #       creation of Btrieve files in BTFILER.  It does the same thing
  1311. #       as the BUTIL -CREATE function, but with one significant
  1312. #       difference:  Error diagnostics are clearer.  This removes (I
  1313. #       think) the most significant problem with the BUTIL - CREATE
  1314. #       process.  Someday an interactive create utility will be part
  1315. #       of BTFILER, but until then, this will have to do...
  1316. #
  1317. #       Case is not important, and some fields are optional (as
  1318. #       noted in comments).
  1319. #
  1320. #       These are the fields possible listed in order of appearance
  1321. #       in the file level settings section:
  1322. #
  1323. #               RECORD LEN=n
  1324. #               PAGE SIZE=n, multiple of 512
  1325. #               VARIABLE=<YES or NO>
  1326. #               BLANK TRUNCATION=<YES or NO>        OPTIONAL!
  1327. #               DATA COMPRESSION=<YES or NO>
  1328. #               FREE SPACE THRESHOLD=<10, 20 or 30>
  1329. #               ALTERNATE FILE=<filename>       OPTIONAL if no alternate key
  1330. #               INCLUDE DATA=<YES or NO>        OPTIONAL!
  1331. #               NUMBER OF KEYS=n
  1332. #
  1333. #
  1334. # These are file level settings, with more details...
  1335. #
  1336. RECORD LEN=131
  1337. #
  1338. # In the Help menu, see "Calculate Page Size" to find
  1339. optimal size.
  1340. #
  1341. PAGE SIZE=1536
  1342. VARIABLE=NO
  1343. #
  1344. # BLANK TRUNCATION is only meaningful with variable length
  1345. #       records, so this BLANK TRUNCATION= line is optional.
  1346. #
  1347. BLANK TRUNCATION=NO
  1348. DATA COMPRESSION=NO
  1349. #
  1350. # FREE SPACE THRESHOLD=n, where 'n' is 10, 20 or 30 ONLY!
  1351. #
  1352. FREE SPACE THRESHOLD=20
  1353. #
  1354. #  ALTERNATE FILE=fname, where fname is the name of a file like
  1355. #         UPPER.ALT.  This line is optional IF no ALTERNATE=YES
  1356. #         key segments exist.
  1357. #
  1358. ALTERNATE FILE=UPPER.ALT
  1359. #
  1360. #  INCLUDE DATA=<Y or N> is used to determine if the file is key only
  1361. #         Data only, or key and data.  INCLUDE DATA= line is OPTIONAL!
  1362. #
  1363. #  For KEY ONLY:   INCLUDE DATA=NO
  1364. #                           NUMBER OF
  1365. KEYS=1
  1366. #  and key length is == to record length. #
  1367. #  For DATA ONLY:  INCLUDE
  1368. DATA=YES
  1369. #                           NUMBER OF KEYS=0
  1370. #
  1371. INCLUDE DATA=Yes
  1372. #
  1373. #  NUMBER OF KEYS= is used as a cross check of the segments
  1374. #       passed below.  In case of a conflict, the option is given
  1375. #       to accept the key count reflected in the segments, or
  1376. #       abandoning creation of the file.
  1377. #
  1378. NUMBER OF KEYS=2
  1379. #
  1380. #  END OF FILE LEVEL SETTINGS!
  1381. #
  1382. #  This marks the beginning of key segment level information.
  1383. #       If I were you, and I were creating BTB files, I would
  1384. #       place a large comment band between each key segment
  1385. #       to remind myself what I think I am doing.  Just a
  1386. #       thought...
  1387. #
  1388. #  The lines for each key segment are in the following order:
  1389. #
  1390. #       START=n, where 'n' is the starting position of the key
  1391. #       LEN=n, where 'n' is the length of the key
  1392. #       MODIFIABLE=s, where 's' is Y or N (or YES or NO or Yes or...)
  1393. #                        Allows Modifications to be made to the key?
  1394. #       DUPLICATES=s, ditto above...Allows Duplicate keys?
  1395. #       ALTERNATE=s, where 's' is as above.  Alternate Collating Sequence?
  1396. #       DESCENDING=s, like above.  Sorts Hi to Lo?
  1397. #       MANUAL=s, like above.  Manual key?  OPTIONAL!
  1398. #       TYPE=t, where 't' is EXACTLY one (case difference OK) of the
  1399. #               following:
  1400. #
  1401. #               "String",
  1402. #               "Integer",
  1403. #               "Float",
  1404. #               "Date",
  1405. #               "Time",
  1406. #               "Decimal",
  1407. #               "Money",
  1408. #               "Logical",
  1409. #               "Numeric",
  1410. #               "Bfloat",
  1411. #               "Lstring",
  1412. #               "Zstring",
  1413. #               "Unsigned Binary",
  1414. #               "Autoincrement",
  1415. #
  1416. #       NULL=n, where 'n' is the decimal NULL value (commonly 0 or 32) OR
  1417. #                  NULL=N/A to explicitly state no NULL value.
  1418. #                  NULL= is OPTIONAL.
  1419. #       SEGMENT=s, where 's' is Y or N (or Yes or N0...).  The number of
  1420. #                  segments with a SEGMENT=No value should be the same
  1421. #                  as the number of keys you declare.
  1422. #
  1423. #
  1424. #  Key 0/Segment 1
  1425. #
  1426. START=1
  1427. LEN=11
  1428. MODIFIABLE=n
  1429. DUPLICATES=n
  1430. ALTERNATE=n
  1431. DESCENDING=n
  1432. TYPE=STRING
  1433. NULL=N/A
  1434. SEGMENT=NO
  1435. #
  1436. #  key 1/segment 1
  1437. #
  1438. START=12
  1439. LEN=30
  1440. MODIFIABLE=y
  1441. DUPLICATES=y
  1442. ALTERNATE=y
  1443. DESCENDING=n
  1444. TYPE=STRING
  1445. NULL=N/A
  1446. SEGMENT=YES
  1447. #
  1448. #  key 1/segment 2
  1449. #
  1450. START=1
  1451. LEN=11
  1452. MODIFIABLE=y
  1453. DUPLICATES=y
  1454. ALTERNATE=y
  1455. DESCENDING=n
  1456. TYPE=STRING
  1457. NULL=N/A
  1458. SEGMENT=NO
  1459. #
  1460. #  That's all, folks!
  1461. #
  1462.  
  1463. Use the following file (supplied on disk as well) that
  1464. allows you to create a Supplemental Index for a Btrieve file
  1465. by describing it in an ASCII file.  Modify it for your needs
  1466. and run the File/Misc. Btrieve Functions/Supplemental
  1467. Index/Create menu option.  When asked, supply the name of
  1468. the BTS file you have modified for your use, or use the
  1469. SAMPLE.BTS file to see how the system works.
  1470.  
  1471. #
  1472. #   This line (and all lines beginning with '#') are COMMENTS.
  1473. #
  1474. #   This is a sample BTrieve Supplemental Index (BTS) file.
  1475. #   It allows for the creation of a supplemental index (key)
  1476. #   for Btrieve files in BTFILER.  It does the same thing
  1477. #   as the BUTIL -SINDEX function, but with one significant
  1478. #   difference:  Error diagnostics are clearer.  This removes (I
  1479. #   think) the most significant problem with the BUTIL - SINDEX
  1480. #   process.  Someday an interactive utility for this will be part
  1481. #   of BTFILER, but until then, this will have to do...
  1482. #
  1483. #   Case is not important, and some fields are optional (as
  1484. #   noted in comments).
  1485. #
  1486. #   This field is the only field possible on the file level section:
  1487. #
  1488. #      ALTERNATE FILE=<filename>           OPTIONAL if no alternate key
  1489. #
  1490. #
  1491. #
  1492. #  ALTERNATE FILE=fname, where fname is the name of a file like
  1493. #     UPPER.ALT.  This line is optional IF no ALTERNATE=YES
  1494. #     key segments exist.
  1495. #
  1496. ALTERNATE FILE=UPPER.ALT
  1497. #
  1498. #  END OF FILE LEVEL SETTINGS!
  1499. #
  1500. #  This marks the beginning of key segment level information.
  1501. #     If I were you, and I were creating BTS files, I would
  1502. #     place a large comment band between each key segment
  1503. #     to remind myself what I think I am doing.  Just a
  1504. #     thought...
  1505. #
  1506. #  The lines for each key segment are in the following order:
  1507. #
  1508. #     START=n, where 'n' is the starting position of the key
  1509. #     LEN=n, where 'n' is the length of the key
  1510. #     MODIFIABLE=s, where 's' is Y or N (or YES or NO or Yes or...)
  1511. #                      Allows Modifications to be made to the key?
  1512. #     DUPLICATES=s, ditto above...Allows Duplicate keys?
  1513. #     ALTERNATE=s, where 's' is as above.  Alternate Collating Sequence?
  1514. #     DESCENDING=s, like above.  Sorts Hi to Lo?
  1515. #     MANUAL=s, like above, Manual key?  OPTIONAL!
  1516. #     TYPE=t, where 't' is EXACTLY one (case difference OK) of the following:
  1517. #
  1518. #                           "String",
  1519. #                           "Integer",
  1520. #                           "Float",
  1521. #                           "Date",
  1522. #                           "Time",
  1523. #                           "Decimal",
  1524. #                           "Money",
  1525. #                           "Logical",
  1526. #                           "Numeric",
  1527. #                           "Bfloat",
  1528. #                           "Lstring",
  1529. #                           "Zstring",
  1530. #                           "Unsigned Binary",
  1531. #                           "Autoincrement",
  1532. #
  1533. #     NULL=n, where 'n' is the decimal NULL value (commonly 0 or 32) OR
  1534. #                NULL=N/A to explicitly state no NULL value.
  1535. #                NULL= is OPTIONAL.
  1536. #     SEGMENT=s, where 's' is Y or N (or Yes or N0...).  The number of
  1537. #                segments with a SEGMENT=No value MUST be one in this case
  1538. #                since only a single supplemental index can be declared
  1539. #                at once.
  1540. #
  1541. #  Segment 1
  1542. #
  1543. START=1
  1544. LEN=22
  1545. MODIFIABLE=n
  1546. DUPLICATES=n
  1547. ALTERNATE=n
  1548. DESCENDING=n
  1549. TYPE=STRING
  1550. NULL=N/A
  1551. SEGMENT=NO
  1552. #
  1553. #  That's all, folks!
  1554. #
  1555.  
  1556.  
  1557.  
  1558.  
  1559.  
  1560.  
  1561.  
  1562.  
  1563.  
  1564.  
  1565.  
  1566.  
  1567.  
  1568.  
  1569.  
  1570.  
  1571.  
  1572.  
  1573.              Appendix B - Using Keystroke files
  1574.  
  1575.  
  1576. Beginning with Version 1.30, BTFILER allows for use of
  1577. keystroke files to automate some program functions.  What
  1578. must be in the file is every keystroke that is required to
  1579. run a particular operation.  The only exception is the
  1580. keystroke required to bypass the registration reminder
  1581. screen.  This screen is passed over if a keystroke file is
  1582. being played.
  1583.  
  1584. Most characters are self explanatory, but some special
  1585. characters may also be entered.  '!' is used where an enter
  1586. key would be played, and '#' substitutes for ESC.  Control
  1587. characters may be entered as the caret key ('^') followed by
  1588. the actual letter (i.e. 'C').  If the characters "^C" are in
  1589. a keystroke file, and they are played back while in a data
  1590. entry field, they will clear the field.  It is easiest to
  1591. use the mnemonic characters (those highlighted on the menus)
  1592. to select options, and note currently there is a limit of
  1593. 200 characters that may be played back.  Below two batch
  1594. files are listed that create keystroke files on the fly and
  1595. then feed them to BTFILER.
  1596.  
  1597.                          BTCLONE.BAT
  1598.  
  1599. echo off
  1600. if '%1' == '' goto NO_PARMS
  1601. if '%2' == '' goto NO_PARMS
  1602. goto OK
  1603. :NO_PARMS
  1604. echo USAGE: BTCLONE existing_file new_clone_file
  1605. goto END
  1606. :OK
  1607. rem
  1608. rem 'C' to choose Clone on opening menu, %1 the Btrieve
  1609. file, '!' for ENTER,
  1610. rem    %2 the New file, '!' for enter, and '###' for ESC's.
  1611. rem
  1612. echo C%1!%2!### >btclone.txt
  1613. btfiler /k:btclone.txt
  1614. del btclone.txt
  1615. :END
  1616.  
  1617.  
  1618.                          BTRESET.BAT
  1619.  
  1620. echo off
  1621. rem
  1622. rem  '#' (ESC) to go to top menu bar, 'O' for Options,
  1623. rem  'E' for Reset Btrieve, and
  1624. rem     Lots of "#' (ESC) to get back out.
  1625. rem
  1626. echo #OE### >btreset.txt
  1627. btfiler /k:btreset.txt
  1628. del btreset.txt
  1629. :END
  1630.  
  1631.