From: Bob Alston on
I am not aware of such but if there is such, maybe someone will
enlighten me. I only know of vba code - which I have - to show who is
connected. Then you must manually get each user - using computer name -
to close their access app.

Bob
From: Marshall Barton on
Bob Alston wrote:

>I am not aware of such but if there is such, maybe someone will
>enlighten me. I only know of vba code - which I have - to show who is
>connected. Then you must manually get each user - using computer name -
>to close their access app.


You would need some kind of network wide flag that that your
program constantly (once every minute?) checks and when the
flaf is sets executes the Quit method.

SInce you would have no idea what each user is doing at the
time, it would have to be more elaborate and warn users that
it will happen in 10 os so minutes to give them a chance to
gracefully close out of your program. I can be done, but
because users may not be in front of their computer at the
time, this whole concept is not safe.

Assuming your program is split into front and back ends and
your end objective is to update the front end on each
machine, you would be far better off using a dynamic updater
program such as Tony's Auto FE Updater available at:
http://www.autofeupdater.com/

--
Marsh
From: (PeteCresswell) on
Per Marshall Barton:
>You would need some kind of network wide flag that that your
>program constantly (once every minute?) checks and when the
>flaf is sets executes the Quit method.
>
>SInce you would have no idea what each user is doing at the
>time, it would have to be more elaborate and warn users that
>it will happen in 10 os so minutes to give them a chance to
>gracefully close out of your program. I can be done, but
>because users may not be in front of their computer at the
>time, this whole concept is not safe.

I've done this on a couple of applications.

The "Home" screen is always open - invisible when the user opens
another screen, but still open.

It's Timer() event fires once a second looking for a semaphore
file: something like H:\Whatever\KillFile.txt.

When it finds such a file, it opens up a dialog with it's own
Timer().

The dialog presents whatever text is in KillFile.txt and wraps it
in something like "The application will shut down in two minutes
unless you click the 'Do NOT Shut Down' button".

Clicking the "Do NOT Shut Down" button buys the user another 10
minutes, but if the user does not click that button the code does
an Application.Quit.

Main use for this is to deal with people who leave the app open
overnight and/or over weekends - preventing updates
to/maintenance of the back end.
--
PeteCresswell