What Is a Microsoft Access Application?

Authors Avatar

What Is a Microsoft Access Application?

People use a database to perform data management tasks, such as storing, retrieving, and analyzing data about orders and customers. A Microsoft Access application is made up of the same objects as a Microsoft Access database i.e. tables, queries, forms, reports, macros, and modules. The objects are stored in one or more Microsoft Access database (.MDB) files. What makes an application different from a database is how you, the application developer, tie the objects together into a coherent system. An application organizes related tasks so that the user can focus on the job at hand, not on the application or the program used to develop the application.

When you build a Microsoft Access application, you work almost entirely with objects, their properties, and the events that occur on forms. Here's how it works:

An application consists of objects  Your application is made up of objects that users see and use directly (forms and reports) and supporting objects that control how the forms and reports work (tables, queries, macros, and modules). You build the forms and other objects in their respective Design views.

Objects have properties you can set  You set objects' properties to make them look and behave the way you want. For example, all forms have a DefaultEditing property that specifies whether users can edit data on the form or only view it. Once you set the property, the form opens automatically in the correct mode. By setting properties, you make your objects behave more intelligently.

Forms respond automatically to events  While people use the forms in your application, their actions e.g. changing data in a field, clicking a command button, moving the mouse e.g. are recognized by Microsoft Access as events. Microsoft Access responds to these events automatically. For example, when a user changes the data in a text box, Microsoft Access checks to make sure that the data is the right data type. When a user clicks a command button, Microsoft Access displays the button as sunken.

You can add your own, custom response to an event  You can use either a macro or an event procedure to add the response you want to an event. An event procedure is an Access Basic procedure you write that's attached to a form, report, or control; it's executed when a specified event occurs. You specify in the event procedure or macro what you want to take place when the event occurs. For example, you can change object properties, open or close objects, or manipulate data. You use the event properties of the form to determine whether in response to an event, Microsoft Access runs a macro or an event procedure. For example, to have a macro run in response to a command button's Click event, you set the button's OnClick event property to the name of the macro.

You can extend Access Basic with external libraries  In addition to writing your own event procedures, you can use Access Basic to call external procedures in Microsoft Access library databases (MDAs) and in dynamic-link libraries (DLLs). For example, you can enable or disable menu commands by calling functions in the DLLs that are part of Microsoft® Windows™.

The following illustration shows the building blocks you use to build a Microsoft Access application, starting at the top with the elements you work with most frequently.

Where Is My Application's Brain?

If you've developed database applications using other products, you might expect to write a main program in Access Basic that makes your application work. The main program would be the application's brain; you'd use it to tell the objects how to appear and react, and how to process the data, much as the manager of an office delegates different projects.

Join now!

With Microsoft Access, the objects manage themselves. There is no main program. For example, suppose you want something to happen when the user clicks a button. You don't need code that checks to see whether the user clicks the button. You attach the code to the button so it's executed when the Click event occurs. When the event occurs, Microsoft Access runs your code automatically.

Laying the Groundwork

Here are the first steps in building a Microsoft Access application i.e. the steps you take before you build your first form:

Step One: Define the application's purpose ...

This is a preview of the whole essay