Access 2002: Building a Simple Desktop and Web Application
- Understanding Access's Approach to Application Design
- Creating an Access Application from a Template File
- Touring the Contact Management Application
- Using the Switchboard Manager
- Exploring Form Design View and VBA Class Modules
- Downloading Templates from the Microsoft Office Update Site
- Saving a Form As a Data Access Page
- In the Real World--Putting What You've Learned in Perspective
Master an essential facet of this powerful database development platform. Detailed, step-by-step instructions guide you through the process of designing an Access application. Using the Database Wizard should help you quickly understand the components and comprehend their behavior.
This sample chapter is excerpted from Special Edition: Using Microsoft Access 2002.
Understanding Access's Approach to Application Design
Unlike other members of Microsoft Office XP, Access 2002 requires that you build an application to take advantage of the product's power as a database development platform. Word 2002 and Excel 2002 let you automate simple repetitive operations by recording Visual Basic for Applications (VBA) macros. Access 2002 supports a set of macro commands for compatibility with previous versions, but Access macros don't use VBA. Access doesn't capture your mouse clicks and keystrokes and turn them into a series of macro commands or VBA code. It's up to you to design and implement the Access applications you need for your database projects.
A full-scale Access application involves at least the following three basic Access object types:
Tables that store the data you or others add to the database
Forms for displaying and entering data, controlling the opening and closing of other forms, and printing reports
Reports to print detail information, summary information, or both, in tables
Most Access applications also use Query objects to filter, sort, and combine your data, and Module objects to store VBA code. Access 2002 forms can (and usually do) contain VBA code in a special type of Module object, called a Class Module. All objects that make up your application are stored in a container called a Database object, which is a single file with an .mdb extension, such as Northwind.mdb. Access is unique in that it can store an entire database application in a single file. Other desktop databases, such as Microsoft Visual FoxPro, require multiple files to store their objects.
New Access users often find it difficult to "get a grip" on how to start developing a self-contained database application. Dealing with an unfamiliar set of objects tends to intimidate first-time database developers. Fortunately, Microsoft includes with Access 2002 various wizards that guide you, step by step, through complex tasks. One of the most accomplished of the Access wizards is the Database Wizard that creates a typical Access 2002 "starter" application from a set of prefabricated database templates. In this chapter, you use the Database Wizard to create a relatively simple but useful Contact Manager application. Then you explore the objects generated by the Wizard to gain perspective on the relationship of Access objects and learn how they're integrated within a typical Access database application.
If you're upgrading from Access 97 to 2002, the following features introduced by Access 2000 are discussed in this chapter:
Subdatasheets, which open when you click a plus sign to the left of the first field in Table Datasheet view. Subdatasheets automatically display records of another table that's related to the current table.
Visual Basic for Applications code editor, which Access 2002 shares with other Office applications. Access 97 and earlier used its own VBA editing window for code modules.
NOTE
This chapter assumes that you've already installed Access 2002. If you haven't, see the "Access 2002 Installation" section of Chapter 1, "Access 2002 for Access 97 and 2000 Users: What's New."