home *** CD-ROM | disk | FTP | other *** search
- 79
- ===============================================================================
- MICROSOFT DATABASE EXAMPLES
- December 12, 1989
- ===============================================================================
-
- 74
- The example applications provided with Microsoft Database are explained
- in detail in the User Guide, Volume 2, Chapters 21 through 25.
- This document explains the directory structure of the examples disk,
- and lists significant changes made to the applications since the User
- Guide went to press.
-
- The example applications are provided for demonstration purposes only and
- should not be assumed to be suitable for commercial use without further
- modification. Many of the screens have been created at VGA resolution, and
- some of them may require adjustment with the Form Designer module for
- display in other resolutions.
-
-
- EXAMPLES DISK DIRECTORY STRUCTURE
- ---------------------------------
- The root directory contains four subdirectories, IDEAS, INVENTRY,
- MAILING, and TRADING. Each contains example data and programs relating to
- one of the chapters in the User Guide.
-
- IDEAS contains a number of example programs relating to Chapter 25, plus
- some additional items. One of these is a program, GAME.SBP, which
- illustrates the ability of Microsoft Database's DML programming language
- to handle unusual specifications. There is also a small two-file dBase
- application, which you may examine either by opening files and browsing
- or by running the query CLITEL.SBQ.
-
- INVENTRY contains an Inventory Control application, which is described in
- Chapter 22. The application is operated from within Microsoft Database's
- normal menu environment, and is designed around a set of forms. It uses
- memory-resident DML subroutines to execute procedures triggered by
- user-defined pushbuttons.
-
- MAILING contains a USA oriented Mailing List Management application,
- driven entirely by a DML program. User access is fully controlled by the
- program. The application is described in Chapter 23.
-
- TRADING contains a system for the hypothetical Microsoft Securities
- Trading firm. This shows how a professional business systems analyst could
- use Microsoft Database to develop a full-scale database application. The
- application is described in Chapter 24.
-
-
- MODIFICATIONS TO THE TRADING APPLICATION
- ----------------------------------------
- Version 1.00 December 1989
-
- GENERAL
- -------
- 74
-
- 74
- 1. The monetary fields in the TRANS file are defined as calculated
- fields, whose values are derived from values held in the STOCKS,
- CURRENCY and CLIENTS files. These definitions effectively
- demonstrate the power of file definition. However a working
- application would not use this method of deriving monetary
- amounts, as the values will be recalculated using the latest data
- each time a TRANS record is updated. The transaction value may
- alter as a result of entering a certificate number or updating the
- record after a certificate advice or contract note has been sent.
-
- A better method of deriving the relevant values would be as
- follows:
-
- - Define the relevant fields as simple text or numeric rather than
- read-only calculation
- - Request entry during Transaction Entry of the first few fields
- including the Client, Trans_Type and Quantity
- - Derive the calculated results using program commands or form
- calculations rather than in the file definition
- - Display the calculated results and store the record
-
- 2. Report programs were originated from the Form Designer. When
- creating a report, the Form Designer generates a .SBV form and a
- .SBP report program. The original forms named STKR*.SBV are
- included. The report programs were modified as detailed below and
- their names changed to STKR*E.SBP. The original programs were then
- deleted. You can re-create the original programs by opening the
- form equivalents in the Form Designer then saving them.
-
- 3. Entering and editing of radio button fields follows the Windows
- standard but may not be intuitive. When in a radio button group
- you move from one to another using the up/down cursor keys. You
- select a button using the Space bar.
-
- 4. Some of the routines offer a choice of color screen-oriented or
- monochrome report-oriented forms. Screen forms should use screen
- fonts and printer forms printer fonts. The fonts on the report-
- oriented forms are for the most part available with a Hewlett-
- Packard LaserJet Series II set to 150 dpi. (The exception is
- System 9pt for which Microsoft Database generally substitutes
- Line Printer 8pt). To achieve satisfactory printed results you must
- first install your own printer under Windows and identify it to
- Microsoft Database using Printer Setup on the Set menu. You can
- then edit the forms provided to substitute fonts that are
- available with your printer and resolution.
-
-
- SPECIFIC CHANGES
- ----------------
- Modifications made after first printing of Microsoft Database Manual Chapter
- 24 are as follows:
-
- 1. STKM modified to:
- - open form Banner at start
- - include About option on File menu to display Banner (at m17)
- - STATUS OFF at start and STATUS ON at end
- - give display/print option for Documents other than labels
- - on entry to Certificate advices if CERTS exists remove it
- - on entry to Contract notes if INVS exists remove it
- - if certificate advices or contract notes displayed then clear
- screen before selecting next option
- - SELECT WHERE on TRANS before Statements to turn off filter
- - trap error 11 generated by Cancel on ASK filter dialog
- - SELECT FIRST before merging LEINVS.SBT
- - Correct REQUEST syntax before Cert or Invoice Labels
- - OPEN FILE "CERTS" or "INVS" before Cert or Invoice Labels
- - Remove spurious WHERE from routine at m341
- - Correct LABELS USING syntax
-
- 2. Report programs modified to:
- - trap errors
- - give repeat print option
- - eliminate pathname from OPEN file statements
- - eliminate ASK from WHERE and ORDER sections
- - put first line of heading including date into string
- - return to STKM with ret% flag set
- - have new filenames ending in E.SPB
-
- 3. Report program STKRRE modified (see manual pp 25-19) to:
- - order transactions by transaction number within stock
- - show summary table of commissions by stock
- - put headings into strings and set strings to null prior to
- summary table print
- - avoid attempt to DIM arrays if not first time around
-
- 4. STKFC, STKFS and STKFT modified to:
- - use FILE in place of OPEN FILE
- - FORM or FORM 1 in place of VIEW before pushbutton wait
- - Branch around FORM or FORM 1 first time through
- - after new record Enter make new record the current record
- - remove BLANK FORM after Delete
- - issue SELECT WHERE after CLOSE FORM to remove any filter
-
- 5. STKFC and STKFS print routines modified to SELECT FORM before
- PRINT CURRENT
-
- 6. STKFC modified to:
- - turn off external file display if set by Next page pushbutton
- - before new record Enter set default Class.CLIENTS = P
-
- 7. STKFT modified to:
- - before new record Enter set default Trans_Type.TRANS = b
-
- 8. FYE Stock.STOCKS made normal numeric rather than constant.
- Constants set to value at beginning of data entry, hence contant
- formula as originally specified gives initial value of zero.
-
-