question re: acQuitSaveNone

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Windows XP, MS Access 2000
======================
Hi,

I have the following line of code in the OnClick property of a button on a
form:
DoCmd.Quit acQuitSaveNone

I wanted to confirm (and make sure there are no pitfalls) that if multiple
instances of the form/database are open at the same time on different (or
same) machines, clicking on this button will close only that particular
instance of the database/form, and not all the databases that are open at
that time.

Thanks.

-Amit
 
Hi Amit

It will terminate the current instance of Access and therefore implicitly
close the currently open database. It will not affect any other machines.

The acQuitSaveNone applies only to any objects you currently have open in
design view - it does not prevent modified data from being saved.

If you are sharing a database on multiple machines, you should really split
it into a shared back-end (containing only the data tables) and a front-end
(containing all your queries, forms, reports and code). See here for Tony
Toews' excellent resource on the subject:
http://www.granite.ab.ca/access/splitapp/index.htm
 
I was under the impression that you can only have one database open per
copy of Access running?

The Quit method will close the application that calls it, but only that
instance of the application.

Therefore, it will only close that database, and not any others (as they
will each have a separate instance of Access running).

This is different to say Excel, as you can have many workbooks open in one
instance of Excel, and the Application.Quit command will close all of them.

Cheers

John Webb
 
Back
Top