| User since: |
Mar 26, 2002 at 03:32 UTC
|
| Last here: |
Oct 01, 2012 at 01:45 UTC
(33 weeks ago) |
| Experience: |
9710
|
| Level: |
Prior (17)
|
| Writeups: |
1577
|
| Location: | n/a |
| User's localtime: |
May 19, 2013 at 08:36 GMT+11
|
| Scratchpad: |
View
|
|
<3 wassercraaaaretats
l33t monitor code from coruscate
#!c:/perl/bin/perl -w
$|++;
use strict;
use Win32::API;
sub MONITOR_ON () { -1 }
sub MONITOR_STANDBY () { 1 }
sub MONITOR_OFF () { 2 }
Win32::API->Import('user32', 'SendMessageA', 'NNNN', 'N');
Win32::API->Import('user32', 'FindWindowA', 'PP', 'N');
my $hwnd = FindWindowA('Shell_TrayWnd', 0);
SendMessageA($hwnd, 0x112, 0xF170, MONITOR_STANDBY);
sleep 6;
SendMessageA($hwnd, 0x112, 0xF170, MONITOR_OFF);
sleep 6;
SendMessageA($hwnd, 0x112, 0xF170, MONITOR_ON);
|