Detect if table is in use.

stephen81

Registered User.
Local time
Today, 03:20
Joined
Nov 27, 2002
Messages
198
I've got a temporary table which I'm using as the source for a mail merge. I need to either delete the table when it is no longer being used for the mail merge or be able to test to see if it is being used at that moment.
Can anyone point me in the right direction?
 
When the mail merge is completed display a message box asking the user if the mail merge was sucsessful, if it was, the user will click "Yes" place your code to delete the temp table there...
 
Is there a way to only display the message once the mail merge has completed though? Or should I just display it and hope they don't flick back to the access window and see the message before they've finished the mail merge?
 
to be honest I don't know much about mail merges, but I think it should be possible to detect when a mail merge has finished and display the message box .

Let's hope someone else reading this knows more!
 
stephen81 said:
I've got a temporary table which I'm using as the source for a mail merge. I need to either delete the table when it is no longer being used for the mail merge or be able to test to see if it is being used at that moment.
Can anyone point me in the right direction?
I trust that you are not sharing that temp table with multiple users. ;)

Why not delete the contents of the temp table at the beginning of your procedure for the mail merge? This will do just that...
Code:
CurrentDb().Execute "DELETE * FROM [YourTableNameHere]"
 

Users who are viewing this thread

Back
Top Bottom