I'm running windows 2008 server. I tried googling and looking on stackoverflow for doing this without adequate results.
I want to run a bit of automation on login/unlock of my windows box. What the automation should do should be different based on whether I'm logging in/unlocking the computer locally vs remotely. What the automation actually does is irrelevant to this question.
Some context: If I login/unlock locally I want to start a program. If login remotely I want to kill that program (I already have scripts to do both). I just don't know how to trigger each script based on the login type.
Is there a way to detect or trigger based on the type of login/unlock remote vs local?
Create 2 tasks