Page 1 of 1

Using Scrolllock as Message Notifier (no blink)

Posted: Sat Mar 14, 2009 9:02 pm
by p.parker
First of all: I love PopTray :D
And sry for bad english...

I searched a solution, that my scrolllock LED will turn on if i receive an mail.
I know there is a plugin... but i don't like the flashing...

So i found a way to simulate the keypress with a tiny VB-Script.
Then i made 2 small batch scripts to get it work.

Because i have no idea how to turn the LED off, if there is no mail stored in PopTray, you have to run a script to do it.

Now the codes:

(Create files with Right-Click -Y New -> Text File , then rename)
1. Create the VB-Script "scrollock.vbs"

Code: Select all

dim WshShell
set WshShell = WScript.CreateObject("WScript.Shell")
WshShell.SendKeys "{SCROLLLOCK}"
2. Batch-Script "Email.bat"

Code: Select all

IF exist D:\Programs\newmail.txt GOTO END
3. Batch-Script "Email off.bat"

Code: Select all

IF exist D:\Programs\newmail.txt GOTO DOIT
del D:\Programs\newmail.txt
You can edit the Paths as you like... Make sure scrolllock.vbs is stored there...

Now you have to set a Rule in PopTray like this:

To turn LED off you have to run the Script "Mail off.bat".
Do not just press the Scrolllock Button ;)

I know it's not the best solution, but so far its a good way for me.
If you have any improvement suggestions let me know :)