rbaron
New member
- Local time
- Today, 13:12
- Joined
- May 20, 2020
- Messages
- 6
Hi everyone!!!
I have a program we use at work, I work for the province's telephone company (I'm in Canada 'eh!?
).
I am tracking users, and what PC they are on, and when they log in and out, that way if I have to update I can just ask that person to log out.
I have some code run on the load and the unload and for the most part it works.
Sometimes tho, if the user exits in an abnormal way, the unload portion of the code doesn't execute, and there's just no timestamp placed in the 'logout time' field. So next time that PC or user logs in again, is now show kind of, that they're logged in twice because no logout was recorded.
I did a select query to find multiple instances of the same pc and username with logout field null. Now I wanted to run an update query on that select query to stamp a logout time in the first record of the 2, but it won't let me.
I kind of want something that runs when the program starts, checks if there;s other instances of PC_NAME with LOGOUT_TIME as null (this indicates a logout wasn't recorded) and automatically stamp the logout time on the first record.
I'm getting old and rusty, and I'm an amateur at best... can someone provide some guidance please and thanks!
I have a program we use at work, I work for the province's telephone company (I'm in Canada 'eh!?


I am tracking users, and what PC they are on, and when they log in and out, that way if I have to update I can just ask that person to log out.
I have some code run on the load and the unload and for the most part it works.
Sometimes tho, if the user exits in an abnormal way, the unload portion of the code doesn't execute, and there's just no timestamp placed in the 'logout time' field. So next time that PC or user logs in again, is now show kind of, that they're logged in twice because no logout was recorded.
I did a select query to find multiple instances of the same pc and username with logout field null. Now I wanted to run an update query on that select query to stamp a logout time in the first record of the 2, but it won't let me.
I kind of want something that runs when the program starts, checks if there;s other instances of PC_NAME with LOGOUT_TIME as null (this indicates a logout wasn't recorded) and automatically stamp the logout time on the first record.
I'm getting old and rusty, and I'm an amateur at best... can someone provide some guidance please and thanks!
Last edited: