In this tip, Processing Message, I am going to show you how to create a form that will display a ‘Please Wait – Query Being Processed’ message, whilst the query is being processed.
If you have a very large database, a complex query and a slow computer, sometimes the processing of a query can seem to take a very long time for the user. So, a little form with a processing message, telling the user that the Query is in process, may allay some fears that ‘nothing’ is happening.
The first thing you need to do is set up your form. To do this: Create an unbound form, i.e. choose to ‘Create a form in Design View’ from the options listed, in Microsoft Access 2003 or earlier, or from the 'Ribbon' , 'Create' > 'Form Design' in Microsoft Access 2007 or later.
Set the following properties for the form (to open the properties window of the form right click in the upper left-hand corner of the form, in the grey square where the two rulers meet, then select ‘properties’ from the drop down list or easier yet, just click on F4).
With the Properties window open, click on the Format Tab and set the following properties:
Caption: Query In Progress
Then, switch to the ‘Other’ tab and set the following properties:
Add a label to your form adding the following text:
“Please Wait – Query In Progress"
Close and Save this form as ‘QueryInProgress’
Next you will need to create a Macro to both run the query and display the form. To do this:
Microsoft Access 2003 or earlier
Click on ‘Macros’ and add the following Actions (underlined) and their associated properties (italics) to the new Macro:
Form Name – QueryInProgress View – Form Data Mode – Read Only Window Mode – Normal Object Type – Form Object Name – QueryInProgress
Query Name – Name of your query View - Datasheet
Object Type – Form Object Name – QueryInProgress Save - No
Close and save this Macro, call it QueryInProgressMacro
Microsoft Access 2007 or later
On the 'Ribbon' select the 'Create' tab, and in the 'Macros and code' section, click on the 'Macro' button.
Add the same actions (underlined) and properties (italics) as for Microsoft Access 2003 to the Macro.
Close and save the Macro, call it QueryInProgressMacro
Now, run this Macro anytime you wish to run your query and display the ‘Please Wait’ form.
I hope this tip, Processing Message, is of some benefit to you.