O'Reilly logo

Beginning Access™ 2007 VBA by Denise Gosnell

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

12.2. Optimizing Your Applications

As part of the testing process, you should fine-tune the application to make it run faster and better. You can apply various techniques to improve the real speed, as well as the speed as perceived by users.

12.2.1. Improving Actual Performance

The speed at which your application actually performs can be improved by applying some general design guidelines, coding techniques, and data access techniques. You will now look at each of these in turn.

12.2.1.1. General Design Guidelines

Here are several general guidelines to help improve the actual performance of your applications:

  • Minimize the code and objects in a form. Move the code to a standard module. The more complicated a form is, the longer it takes to load.

  • Minimize the use of subforms because two forms are in memory.

  • Write reusable modules that so you are not rewriting the same code in slightly different ways multiple times. This reduces the amount of code in your application and helps improve speed. For example, instead of having one procedure that enables all controls in one form, another that disables all controls in another form, and two others that disable controls in each of those same forms, write a generic module that enables or disables all controls on the specified form based on whether the enable or disable flag is passed as a variable.

  • Eliminate code that is not used.

  • Make sure that your application is compiled. Also, consider compiling your application into an ACCDE file as described ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required