home *** CD-ROM | disk | FTP | other *** search
-
- (c)Copyright Sequiter Software Inc., 1987, 1988, 1989. All rights reserved.
-
-
- README - Table of Contents
-
- I. The Code Base 4 Libraries
-
- II. Installing Code Base 4
-
- III. Example Programs ('d4more.c' contains some new field routines.)
-
- IV. Converting from Code Base to Code Base 4
-
- V. Converting from Code Base 4.xx to Code Base 4.04
-
- VI. Turbo C 2.0 Problem
-
- VII. Code Base 4.03 Corrections
-
- VIII. Code Base 4.04 Bug Fix
-
- IX. dBEditor
-
- X. Using Code Base with Microsoft Windows
-
- XI. Quick Reference Help
-
-
- The Code Base 4 Libraries
-
- Library files 'T4.LIB', 'M4.LIB', and 'M4CLIP.LIB' were created
- with Turbo C 2.0 and Microsoft C 5.1 respectively. The library
- files 'M4.LIB' and 'M4CLIP.LIB' have also been tested with Quick C 2.0.
-
- The files used to create the pre-built libraries are present on
- the Code Base 4 library diskette.
-
- If you have a different compiler or compiler version, or if you
- with to use Code Base 4 with OS/2, you will not be able to use the
- pre-compiled libraries. Refer to the Appendix on Library building.
-
-
- Installing Code Base 4
-
- With Code Base 4.04 there is one more diskette. Consequently,
- the header files and examples are on the 'Examples, Header Files
- and Source Diskette'. As the source no longer fits on one diskette,
- there are some source files in the "SOURCE" subdirectory of this
- diskette.
-
- As described in the Code Base 4 users guide, you need to copy
- the appropriate Code Base 4 files to the appropriate directory of
- your hard disk.
-
-
- Example Programs
-
- There are several example programs located on the library diskettes:
-
- Program Use
-
- c4convert.c A program which, for a number of files, changes
- character sequences to other character sequences.
- This program extensively uses Code Base 4 routines.
- See below.
-
- d4example.c The program on page 14 of the Code Base 4 users guide.
-
- d4more.c VERY IMPORTANT. This file contains some new, easy
- to use, field routines. It also contains an example
- showing how to use them. Finally, the example program
- shows how to use multiple database files, multiple
- index files, and 'd4seek'.
-
- d4simple.c A very short program which implements data entry,
- database manipulation, and a menu.
-
- d4small.c A program which accesses a database and produces a
- 13.5K executable file under MSC 5.1.
-
- d4learn.c An program for interactively executing the Code Base 4
- database management routines.
-
- n4pull.c The program on page 122 of the Code Base 4 users guide.
-
- w4example.c Windowing, Menuing, Data Entry
-
- x4multi.c A multi-user program for displaying a database.
-
-
- Converting from Code Base to Code Base 4
-
- Program 'c4convert' has been provided to convert Code Base 4 programs
- into Code Base 4 programs. Essentially, the convert program searches
- for character sequences located in the 'from' field of database
- 'convert.dbf'. It transforms these character sequences into the
- sequences specified by the corresponding 'to' field. The data
- in 'convert.dbf' is set up to transform the character sequences
- 'c3', 'd3', 'e3', 'f3', 'g3', 'h3', 'i3', 'm3', 's3', 'u3', 'v3', and 'x3'
- to 'c4', 'd4', 'e4', 'f4', 'g4', 'h4', 'i4', 'm4', 'w4', 'u4', 'v4' and
- 'x4' respectively. The files it operates on are interactively set
- within program 'convert'. By default, it converts and file which
- matches the '*.c' wildcard file specification. All of the identically
- named output files are placed in an output directory. This output
- directory is '\c4' by default. Create the output directory before
- running program convert.
-
- Make sure that the conversions made do not change parts of your
- program which should not be changed. For example, the hexidecimal
- constant '0x37' would be changed to '0x47'. After the above conversion
- is completed, make the following changes:
-
- 1. 'd3main.h' no longer is needed. Remove all references to it
- from your program. The external variables it defined are now
- defined in source file 'd4init.c'.
-
- 2. 's3io' no longer exists. Instead, you will use routine
- 'w4define'. Note that routine 'd4init' automatically creates
- a default window.
-
- 3. The definition of the integer values returned by 'd3select', and
- 'i3select' have been changed slightly.
-
- 4. Routine 'i3go' has one additional return value.
-
-
- Converting from Code Base 4.xx to Code Base 4.04
-
- 1. Routine 'd4go' used to check to make sure the record
- number parameter was less than or equal to the number
- of records in the database. For performance reasons,
- it no longer does.
-
- 2. Rebuild previous Code Base 4.xx programs which must
- coordinate with Code Base 4.04 programs on a network.
- A minor change was made to ensure Code Base 4.04
- 'NDX' file compatibility with dBASE IV.
-
- 3. The default parameters for expression function 'STR'
- have been changed. They are now the same as dBASE and
- Clipper.
-
-
- Turbo C 2.0 Problem
-
- When using the medium, small or tiny memory models, the 'malloc' routine
- does not work correctly when allocating more than '0xF000' bytes of
- memory. Consequently, when using Code Base 4 under Turbo C with these
- memory models, make the following change to source file 'i4reindex.c':
-
- Change line 835 of 'i4reindex.c' from
-
- large = h4alloc_try( allocated = 0xFFDE ) ;
-
- to
-
- large = h4alloc_try( allocated = 0x8000 ) ;
-
-
- Code Base 4.03 Corrections
-
- 1. Clipper Users Only
-
- Code Base 4 now works with Clipper Unique Key NTX index files.
- Ignore the documentation under routine 'i4index' which says that it
- does not.
-
- 2. Avoid using the 'DTOC' function in index file key expressions. Use
- function 'DTOS' instead. dBASE and Clipper format the result
- differently depending on how 'SET DATE' is set. Consequently,
- using function 'DTOC' results in an incompatibility with dBASE
- and Clipper index files.
-
- 3. Note that not all of the Code Base source code fit onto the
- 'source' disk. There is additional source code is sub-directory
- 'source' of the 'Header', 'Example' and 'Source' disk. Make sure
- you copy those extra source files before rebuilding your library.
-
-
- Code Base 4.04 Bug Fix
-
- There is a bug is Code Base 4.04 which only surfaces when using index
- files using the key expression 'VAL(STR_VALUE)'. Note that this function
- is seldom used in index files key expressions. The fix is to change line
- 495 of file 'e4exec.c'.
-
- Current Code
-
- *((double *)r_ptr) = strtod( a.ch, (char **) 0) ;
-
- Line After Fix
-
- *((double *)r_ptr) = c4atod( a.ch, a_len ) ;
-
-
- dBEditor
-
- dBEditor, a handy utility program for quickly accessing dBASE
- data and index files, is present on the Turbo C library diskette.
- The program name is 'EDI.EXE'.
-
- dBEditor also supports interactive window design, calculated fields,
- database relations and single key stroke commands.
-
- You probably can figure out how to use 'dBEditor' by experimentation.
- However, a users guide is available for US$45.00. The user's
- guide is 79 pages long and explains 'dBEditor' completely.
- For the full retail price of US$99.00 there is also a royalty free
- runtime version of dBEditor.
-
-
- Using Code Base 4.04 with Microsoft Windows
-
- 1. Refer to the 'WINDOWS_L' conditional compilation switch in the
- appendix on library building.
-
- 2. To limit the amount of memory Code Base 4 uses, consider calling
- 'd4init_memory' instead of 'd4init'. Call 'd4init_memory'
- once before other Code Base 4 routines are called. Refer to the
- users guide.
-
- Remember to check the return code which the initialization routine
- returns. Under Microsoft Windows, the Code Base 4 'u4error' routine
- returns an error if Code Base 4 runs out of memory. Under DOS,
- lack of memory is treated as a fatal error, and 'u4error' exits
- directly.
-
- 3. Modify 'u4error.c' to display some kind of notification if
- Code Base 4 detects an error. Otherwise, make sure you check
- all return codes. By default, Code Base 4 automatically
- displays error information under the DOS, OS/2 and Xenix versions
- only.
-
-
- Quick Reference Help
-
- The Turbo C library disk contains a file 'quick.ref' on
- the root directory which contains a prototype and very short description
- of each commonly used routine. This information can be printed or refered
- to from your text editor.
-