O'Reilly logo

Special Edition Using Access 97, Second Edition by Roger Jennings

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

Writing a Function that Uses Database Objects

All database objects that you can create and manipulate with Access's graphical development environment also can be created and manipulated with Access VBA code. You can use Access VBA to create a new table, to add records to the table, to define a query to select records from the table, to create a form to display the data, and then to print a report. In other words, you can use Access VBA to create an application exactly the same way you use the dBASE language or PAL. The purpose of Access's graphical development environment, however, is to minimize the need for code in applications.

The nilTestQuery function you write in the following example uses the QueryDef and Database object data types to ...

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