Microsoft Access 2010 Bible

(Rick Simeone) #1

Chapter 26: Bulletproofing Access Applications ..........................................................................


899


the most disinterested and unimaginative user will resist the temptation to “improve” the forms
and reports you’ve carefully crafted.

Perhaps the most important step to bulletproofing applications is to provide end users with the
Access runtime environment, described later in this chapter. The Access runtime provides full
support — well, almost full support — of all the features you build into Access databases without
giving end users the tools needed to change the underlying database structures. (Unrestricted
access to tables could mean deletion or modification of multiple records. Even though Access
warns of most changes to data, an untrained user may ignore these warnings and proceed with
the changes.)

Applications that have been bulletproofed protect the data through a number of techniques:

l (^) Rock-solid construction: No database exhibiting unexplained crashes, general protection
faults (GPFs), or other instabilities can be considered bulletproof. First and foremost, an
Access application must be reliable and free from programming bugs that lead to crashes
or other undesirable behavior.
Cross-Reference
Chapter 14 explains how to use the built-in debugging tools and how to test a database to improve its reliability.
l (^) Self-documenting behavior: Built-in security features — helpful text on the screen, warn-
ing messages that caution the user when something dangerous is about to happen, and
context-sensitive help to explain how the application is meant to be used — guide the user.
l A controlled flow through the application: Controlling an application’s flow channels
the user through the application in a logical sequence that’s best suited to the way in
which the application was envisioned being used.
l (^) Error handling that stops otherwise damaging actions on the part of the user: You
shouldn’t let a user destroy, delete, or modify data without understanding what’s happen-
ing. Whenever possible, warn the user before making an irreversible action.
l Feedback so that the user is never left in the dark about the database status: Long oper-
ations are indicated by progress meters, an hourglass cursor, or other visual indicators.
Identifying the Principles of Bulletproofing
Bulletproofing means much more than simply writing the right VBA code in your Access programs.
You need the right attitude — one that leads to the careful, methodical approach necessary to suc-
ceed in bulletproofing your applications. In other words, you need to approach your development
as a professional.
In this section, I give you some guidelines to follow to bulletproof your applications. (If you’re
already employing these procedures in your applications, you can look at this section as a series of
friendly reminders.)

Free download pdf