11/22/2024 3:56:40 PM
|
|
slxdeveloper.com Community Forums |
|
|
|
The Forums on slxdeveloper.com are now retired. The forum archive will remain available for the time being. Thank you for your participation on slxdeveloper.com!
Forum to discuss building external web applications for SalesLogix. View the code of conduct for posting guidelines.
|
|
|
|
Web Client - user logged out
Posted: 20 Feb 07 2:42 PM
|
fiogf49gjkf0d I am trying to track the time each user logs in and out of the web client. I was thinking of implementing this as a web service using ASP.NET 2.0 Object caching. I would make an initial call to the service from the onlogin action passing the userid. The service would insert the login data and userid into an audit table in the slx db as well as creating a cache item with a sliding timeout of say 5 minutes and a cacheitemremovedcallback event handler. I was also going to place a call to the service in pingtimer.html to refresh the cache entry for the userid since this seems to be called quite regularly while the web client sits idle. After the user logs out or closes the browser, the cache will timeout and the cacheitemremovedcallback event handler will enter the logout time in the database for that userid. Does this seem like a good approach? I wish there was a way to tell if a userid is still logged in from outside of the Web Client then I would not have to fool with pingtimer.html. I would just do the check each time the cache item expires and then reinsert the cache item if the user is still logged in. |
|
|
|
Re: Web Client - user logged out
Posted: 21 Feb 07 2:45 AM
|
fiogf49gjkf0d It seems like a good idea - trying to ascertain when a user logs out of the web client is a pain. It could be done by simply inserting a login record to the database in the onlogin action, then have an event that fires when they (i) click logout to insert the logout date/time, and (ii) also an onunload event on topnav to do the same thing, in case they close the browser instead of logging out. The onunload event is supposed to be a little bit unreliable but its worked everytime ive tested it (the onunload event fires when the page is left/closed). Depends how much time you have i guess and how complex you want the facitlity to be....
Thanks, Nick |
|
|
|
You can
subscribe to receive a daily forum digest in your
user profile. View the site code
of conduct for posting guidelines.
Forum RSS Feed - Subscribe to the forum RSS feed to keep on top of the latest forum activity!
|
|
|
|
|
|
|
|