Developing a Database Application:
|
|
dBASE SE is a great rapid application development (RAD) environment. However, many folk are not sure where to start in the development of an application or how to use the tools included with this amazing software.
The purpose of this tutorial is to guide a database developer through the process of creating an application in dBASE SE, from building the database to it's final deployment.
dBASE SE is a 100% pure object-oreinted programming tool. The tutorial project will focus on using the dBASE SE data access objects; it will guide you through the objects used to create forms, reports, and an application menu; and it will show you how to deploy a complete application.
This process will take some time, so this is broken down into individual parts. As a student you can work along when you have time and come back and pick up where you left off. Do not assume that you can just "whip through it" and be done quickly. While the application created during the process of this tutorial is not a "complete" application, it still has many inter related pieces. In the past, users have, for the most part, taken a minimum of one week to complete this project.
NOTE: If you find any typos, errors, or have a difficult time understanding any part of this tutorial, please use the dBASE, Inc. public newsgroups. Information on these can be gotten at the dBASE, Inc. website: http://www.dbase.com. Use the "Help" link, and at the top of the Technical Support page is a link to a webpage that explains how to use the dBASE newsgroups.
This Edition of the Tutorial Project is tailored for dBASE SE.
Support has been added for the "inherit from" menu item when creating datamodules with dQuery. This option was not available in dB2K.01. It is available with dB2K.04 and dBASE SE.
We have removed the use of a Source Code Alias. In the last edition, the Source Code Alias caused more confusion than any other part of the Tutorial. A Source Code Alias is an extremely useful tool and you should considering using it when you build your applications. But there is plenty of new things to learn before introducing this topic.
An onClose event handler has been added to the BASE.cfm form. This event handler is intended to release from memory any form derived from the custom class. Pervious versions of the Tutorial Application could cause system resource problems because forms were not properly released.
We have added some code to the custom combobox control which handles those times when the combobox appears to change data but it doesn't. This code was included in the first edition of the Tutorial, but seems to have gotten lost in the Second edition.
There is one less Chapter in this Edition. dBASE SE does not support building executable files, and therefore "Building and Deploying the Executable" has been removed. A short discussion of how to run a completed application with dBASE SE has been added at the end of Phase VIII.
Finally, the walkthrough application has been restructured so that it will run in dBASE SE. In the previous Edition, the walk through was an executable file. Now it is a collection of source code files.
This is the Second Edition of the Tutorial Project. The first edition was written for Visual dBASE 7.01 by Ken Mayer and last updated November 8, 1999. The text of the Second Edition is a complete face lift so that it corresponds with the many new features offered by dB2K. The updates were made by Michael Nuwer and released June 30, 2001. Among the new features found in dB2K are dQuery/Web, Source Code Aliases, and Dynamic External Objects (DEO). The Second Edition integrates each of these new technologies into the Tutorial Project.
Another significant change that will be apparent to anyone who has worked through the First Edition of the Tutorial is the addition of a new Chapter on Creating Custom Components. In the First Edition, the Tutorial used a pre-created set of custom controls. In this Edition you will create your own custom controls and use them in the application.
Other new material includes a brief discussion of data validation and creating calculated fields in the Chapter on "Creating the DataModules". A new report, the Customer Account Statement report, is added to the Chapter on "Creating the Reports". This report offers some interesting material related to the linkage tables and calling the report.
Other changes include 1) the use of DataModule objects rather than DataModRef objects and 2) the use of TextLabel objects rather than Text objects. Both the DataModule class and the TextLabel class were introduced in February 2000 when Visual dBASE 7.5 was released. The DataModule class reduces much of the complexity associated with dataModRef objects and the textLabel class reduced the memory overhead associated with Text objects.
The Project Explorer is no longer included in the Tutorial. With the introduction of DEO, compiling and building an application has become rather simple. The Project Explorer is, therefore, no longer needed.
For those who have paid very close attention to the code used in the First Edition, you will notice that the canClose method that was in the DataForm.cfm has been moved to base.cfm. Since the DialogForms and the Dataforms were calling this method, it seemed appropriate to locate it so that either form would inherit it.
There are many people who have helped with this Project. The First Edition would not have been completed without:
In addition, there were many folk who helped test the tutorial before the First Edition was released to the general public. Ken received some good comments from various Beta testers, including a lot of re-writes for clarity in the text, a lot of the "Notes" were added based on input from the testers, and some (gasp) bug fixes in the code. These tester were: Robert (Bob) Newman (Bob found a really serious problem in the deployment section of the tutorial, as well as lots of good commentary throughout), Richard Sandies, Frank Polan, Barbara Betcher (Barbara suggested the Goals section for each of the different Phases of the tutorial, and provided screen shots for some of the areas she had concerns over -- this was very helpful), Steve Robertson, Denise Allred, Richard Clark, Bernard Mc Clement, Richard Forrest, and Jørgen Feder. The second group of Beta tester were Roy Manuell, Santo Lo Galbo (Santo tested on the Italian version of Visual dBASE 7, and it worked there, which is good to know), Gerald Lightsey (Gerald provided tons of nit-picky commentary -- which is good -- various typos and minor glitches got found, as well as a few big ones, particularly in the Invoice report), Wes Rue (the first to complete the project through to the end), and Jim Garrett.
The Second Edition of the Tutorial owes a great deal to the dBASE community. Over the last few years that I have been active in the dBASE Newsgroups, I can not remember one cross word directed at "Ken's Tutorial". But there has been a ton of praise and gratitude. The overwhelming support of the user community voiced day after day both encouraged and energized this update.
Ken Mayer encourage Me (Michael Nuwer) to write the update and had faith that I could pull it off. The Second Edition of the Tutorial also benefited from a great group of testers. Tim MacAlpine set the pace during the testing period. He was often the first to find my errors and cleared the path for others. Barbara Betcher, who was a beta tester for the First Edition, offered her help again. The clarity of this document owes much to her detailed comments. Duane Bays and John Creed brought a great deal of experience to the testing period. Their extensive comments saved me from making some big mistakes. I would also like to thank Mario Trzesniowski, Don Archibald, Jean Chenaille, and Don White for offering valuable contributions to this project.
Last Modified: October 25, 2002
The Legal Stuff: This document is part of the dBASE SE Tutorial created by Ken Mayer and Michael Nuwer. This material is copyright © 2002, by Ken Mayer and Michael Nuwer. dBASE SE is copyrighted, trademarked, etc., by dBASE, Inc., the BDE (Borland Database Engine) and BDE Administrator are copyrighted, trademarked and all that by Borland, International. This document may not be posted elsewhere without the explicit permission of the authors, who retains all rights to the document.