I have a C# Windows application that marks the user as logged in in a database when he logs in to application and marks him as logged out when he exits the application.
My problem is that my application does not mark the user as logged out in the database when the user kills the application through the task manager or when the system is restarted without logging out of the application.
Is there any way to mark the user as logged out in these two situations?