views:

1456

answers:

2

I have a Windows XP machine and a Linux machine running Ubuntu. I share the keyboard/mouse from the Windows machine via Synergy. What I would like to do is lock/unlock the Linux machine whenever I lock/unlock the Windows machine.

So I'd like to be able to run a script of some description when Windows either locks or unlocks the screen.

+1  A: 

The standard way in Windows is to write a package (a dll) that subscribes to Winlogon notification events.

I don't know of any tool that provides an easy way to hook into those events, but you could make your package launch a script from some specific place if you really need your actions to be inside one.

Romulo A. Ceccon
A: 

Does that work, given that a screen lock is not technically a logon event?

Thomas S