Chapter 15. Enhancing Reports with VBA


  • How new features for reports can help increase productivity

  • Descriptions of the events available for reports

  • How to use code to add additional functionality to reports

Because of their rich printed view, reports have long been one of the more widely used features in Access. This chapter takes an in-depth look at reports in Access 2010. It starts from the beginning, so if you're already familiar with creating reports in Access, you might want to skip to the sections titled "New in Access 2007" or "New in Access 2010."

The chapter also looks at several ways that you can enhance your reports by adding VBA behind them. You'll explore the various events that are available for reports and sections, and then move into some common uses for those events. Along the way, you'll see some issues that you should look out for as you're designing reports. Finally, you'll examine several new features in reports in both Access 2007 and Access 2010, including Layout view and Report view.

When you write code behind a form, there are certain things to consider, such as the flow of the application, searching for data, data entry, and validation. While reports in Access 2010 are still read-only, they have been greatly enhanced to allow for some of the form-type scenarios that you might have created in the past such as search, sorting, and filtering.


Reports in Access are designed to provide a view of data in a table or query ...

Get Microsoft® Access® 2010 Programmer's Reference now with the O’Reilly learning platform.

O’Reilly members experience live online training, plus books, videos, and digital content from nearly 200 publishers.