Login script to run only upon first login of the day
Posted on 2013-01-23
I need to write a VBscript that will display a message only upon a user's first login of the day. These users move around quite a bit during the day and are always logging into different computers. My initial plan was to have the script look at the user account's last login attribute and only display the message if the last login date is not the same as the current date. However, I started thinking that this might not work because the last login attribute is not replicated to all domain controllers. Also, since this is to be a login script the last login is technically going to be the most recent login so the last login date and the current date would always be the same. Is there a better way to handle this? Oh, I forgot to mention this would be deployed as a login script via GPO.