I ran it and it shows logons but not the logoff
I think that is why people at there own logon and logoff scripts and just append a message to a log file with a batch file that they control.
here is a old method: http://blogs.msmvps.com/kwsupport/2005/02/24/lazy-mans-way-to-track-user-logonlogoff/
--------------
I would think now you would use taskscheduler (Taskschd.msc ) and set up a script to run on some logon and logoff event.
here is someone that made a simple version:
http://www.guidingtech.com/6068/track-work-time-login-lock-task-schedule/
it logs a single users login, lock and logout times. (I would add the username to the script to prevent potential errors)
I am sure there are more professional ways to do this with a VB...