[AccessD] Clean Shut Down of Access When Left Open in RDP
John Bartow
jbartow at winhaven.net
Thu Aug 2 16:08:51 CDT 2018
The problem with the logoff having to force it to close isn't so much the local access processes as the connectivity and cleaning up the data stream and BE locks. Forcing it to close causes data verification and backend problems.
You may ask your IT guy if he can add a "logoff Script" for each account to help alleviate that problem. Have the logoff script check on the process and if it is being used close it gently - i.e. pop up a message and give it some time. The task scheduler can do this as of Windows Vista.
The Task Scheduler has an XML format that describes scheduled tasks, and schtasks.exe has an option to import tasks from an XML file.
To create a logoff script, create an XML file that describes the task you want to create. Make sure to use a trigger of "On disconnect from a user session" and select the log off from "any user" (which requires elevated privileges) and "connection from local computer." Set up all desired logoff actions (such as your logoff scripts) as task actions.
Alternatively, you can set up your task once using the GUI tool, then you can right-click the task where it appears in the task list and select "Export." You will get a save dialog that will allow you to save the task in XML format.
Then script the setup of the task with the following command:
schtasks /create /tn "Task Name Here" /XML "path to xml file here" /ru domain\username /rp "password"
HTH
John B
-----Original Message-----
From: AccessD <accessd-bounces at databaseadvisors.com> On Behalf Of Jim Dettman
Sent: Thursday, August 02, 2018 6:17 AM
To: 'Access Developers discussion and problem solving' <accessd at databaseadvisors.com>
Subject: Re: [AccessD] Clean Shut Down of Access When Left Open in RDP
It will try to close, but just like Excel and Word, if anything stops that (like being in the middle of an edit), then the app will be forced to close and not shutdown gracefully.
Jim.
-----Original Message-----
From: AccessD [mailto:accessd-bounces at databaseadvisors.com] On Behalf Of David Emerson
Sent: Wednesday, August 1, 2018 9:52 PM
To: 'Access Developers discussion and problem solving'
Subject: Re: [AccessD] Clean Shut Down of Access When Left Open in RDP
My IT guy has asked this question:
The Log off policy doesn't just pull the rug out from under the application.. it issues a 'Log off' or 'shutdown' call tot he environment.
Word, Excel etc 'hear' this and close down in an orderly manner.. I'm
hoping the Access application can be made to do this as well.....
Does anyone have an answer for this?
Regards
David Emerson
Dalyn Software Ltd
Wellington, New Zealand
-----Original Message-----
From: AccessD [mailto:accessd-bounces at databaseadvisors.com] On Behalf Of Jim Dettman
Sent: Thursday, 2 August 2018 9:32 a.m.
To: 'Access Developers discussion and problem solving'
Subject: Re: [AccessD] Clean Shut Down of Access When Left Open in RDP
<< Why doesn't MS implement a fix to a problem that has existed for 10 plus years despite many requests for a fix?>>
It's just not easy to do.
They did add a passive shutdown feature, but there is no simply way to actively kick someone off that is in the middle of something when there are multiple instances of the database engine touching the database file.
Jim.
-----Original Message-----
From: AccessD [mailto:accessd-bounces at databaseadvisors.com] On Behalf Of Bill Benson
Sent: Wednesday, August 1, 2018 2:35 AM
To: Access Developers discussion and problem solving
Subject: Re: [AccessD] Clean Shut Down of Access When Left Open in RDP
Why do we always have to "switch" from Access to another platform just to get *reasonable* robustness?
This problem is well documented and there no known solution except less than perfect mechanisms like Chris Symonds or Alvin Meyer KickThemOff solutions, which still are not fool proof, from my viewpoint.
Why doesn't MS implement a fix to a problem that has existed for 10 plus years despite many requests for a fix?
Fortunately in my corporate environment, the backend is always SQL Server or Sharepoint. A purely Access backend on a multi user platform is just asking for trouble.
In the interim, I would initiate a timer on the got focus of every control on every form that closes all forms and exits the database if a certain period of inactivity is reached. 30 minutes is usually adequate. No message to the user, but a scrape of data can be sent to the user in an email telling them which form (s) were open, what field data existed at time of forced exit, and a request to be more responsibe in future. Don't display a "Database will close in XX minutes" messagebox, that will hang the system awaiting their response... but you can pop a dialog form on a timer, with a label and a cancel button. When the timer on that form reaches its preset interval, the form closes and commences database exit routines. If their data isn't saved, too bad.
This has to be one of the most frustrating things in all of Access.
On Wed, Aug 1, 2018, 1:01 AM Jim Lawrence <accessd at shaw.ca> wrote:
> Has anyone looked at SSH or SSL connections as they are built into
> Window10 by default? Extremely robust and resilient.
>
> Maybe it might be better to setup remote users on SQL-Express DB BE as
> it does not require a synchronize connection like a MDB does.
>
> Aside: Ran into a similar problem many years ago and moved the entire
> network's BE to a MSSQL DB and that was an end to corruption issues.
>
> Jim
>
> ----- Original Message -----
> From: "David Emerson" <newsgrps at dalyn.co.nz>
> To: "Access Developers discussion and problem solving" <
> accessd at databaseadvisors.com>
> Sent: Tuesday, July 31, 2018 7:24:11 PM
> Subject: [AccessD] Clean Shut Down of Access When Left Open in RDP
>
> Hi Listers,
>
>
>
> A client has a problem with Access data corruption when a user on RDP
> leaves the Access application open and the users are forcibly logged
> off the RDS servers.
>
>
>
> Is there a way for Access to be closed first before the user is logged
off?
>
>
>
> Regards
>
> David Emerson
> Dalyn Software Ltd
> Wellington, New Zealand
>
>
>
>
>
> --
> AccessD mailing list
> AccessD at databaseadvisors.com
> http://databaseadvisors.com/mailman/listinfo/accessd
> Website: http://www.databaseadvisors.com
> --
> AccessD mailing list
> AccessD at databaseadvisors.com
> http://databaseadvisors.com/mailman/listinfo/accessd
> Website: http://www.databaseadvisors.com
>
--
AccessD mailing list
AccessD at databaseadvisors.com
http://databaseadvisors.com/mailman/listinfo/accessd
Website: http://www.databaseadvisors.com
--
AccessD mailing list
AccessD at databaseadvisors.com
http://databaseadvisors.com/mailman/listinfo/accessd
Website: http://www.databaseadvisors.com
--
AccessD mailing list
AccessD at databaseadvisors.com
http://databaseadvisors.com/mailman/listinfo/accessd
Website: http://www.databaseadvisors.com
--
AccessD mailing list
AccessD at databaseadvisors.com
http://databaseadvisors.com/mailman/listinfo/accessd
Website: http://www.databaseadvisors.com
More information about the AccessD
mailing list