Q: This (http://forums.overclockersclub.com/Monitor_Sleep_Command-t52687.html) wire shows how to manually monitor sleep. Its great, but I want one that will wake too.
Why you ask? Schedule to monitor uptime and downtime. (And no display options are not enough WXP. I do not want a timer).
r
int main (int argc, char * argv []) (977 503 977 503 Sleep (1000), 977 503 Post Message (HWND_BROADCAST, WM_SYSCOMMAND, SC_MONITORPOWER, 1); 977 503 977 503 return 0;) 977 503
So, everyone can see how this can be adjusted to Monitor awake?
Re:Originally posted by: guy
Here, try this: http://s95030374.onlinehome.us/files/Montool.zip
Just basically compiled the above code in DevC++ and added commandline switches. So run it with any of these:
montool -off
montool -on
montool -standby
much thanks! i don't have VC++ installed right at the moment…
guy: For a free C++ compiler for Windows, take a look at Microsoft Visual Studio 2005 Express. Yes, this does contain .NET, but you can compile C++ exes that don't use .NET.
http://lab.msdn.microsoft.com/vs2005/default.aspx
Re:Originally posted by: guy
Here, try this: http://s95030374.onlinehome.us/files/Montool.zip
Just basically compiled the above code in DevC++ and added commandline switches. So run it with any of these:
montool -off
montool -on
montool -standby
PERFECT.
Thanks a lot! :beer:
Re:PM sent – checkout the ATOT FTP server
Re:Here, try this: http://s95030374.onlinehome.us/files/Montool.zip
Just basically compiled the above code in DevC++ and added commandline switches. So run it with any of these:
montool -off
montool -on
montool -standby
Re:This is what was mentioned on the other site (along with changes suggested by guy). [Unless there's a way for you to host file somewhere probably not worth bothering though since I don't receive email]
Re:Post the source code or E-Mail to me as a zip file and I will see what I can do.
To lazy to download and build source file myself.
Re:ANyone decent with compiling?
I get this error when I download the free MS stuff:
C:\Program Files\Microsoft Visual C++ Toolkit 2003>cl Sleep.cpp
Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 13.10.3077 for 80×86
Copyright (C) Microsoft Corporation 1984-2002. All rights reserved.
Sleep.cpp
Sleep.cpp(3) : fatal error C1083: Cannot open include file: 'windows.h': No such
file or directory
Re:Originally posted by: guy
Nice, now can you make us some EXE out of that?
Or can someone lay out how to do this in windows?
I've tried downloading a couple compilers but they all bitch about something different.
Re:Originally posted by: guy
Turn off:
PostMessage(HWND_BROADCAST, WM_SYSCOMMAND, SC_MONITORPOWER, 2);
Standby:
PostMessage(HWND_BROADCAST, WM_SYSCOMMAND, SC_MONITORPOWER, 1);
Turn on:
PostMessage(HWND_BROADCAST, WM_SYSCOMMAND, SC_MONITORPOWER, -1);
Nice, now can you make us some EXE out of that? ![]()
Re:Originally posted by: guy
Turn off:
PostMessage(HWND_BROADCAST, WM_SYSCOMMAND, SC_MONITORPOWER, 2);
Standby:
PostMessage(HWND_BROADCAST, WM_SYSCOMMAND, SC_MONITORPOWER, 1);
Turn on:
PostMessage(HWND_BROADCAST, WM_SYSCOMMAND, SC_MONITORPOWER, -1);
Cool. Thanks! So the rest stays the same? (I can't program). Now to look for a simple windows compiler… Is this C++?
Re:Turn off:
PostMessage(HWND_BROADCAST, WM_SYSCOMMAND, SC_MONITORPOWER, 2);
Standby:
PostMessage(HWND_BROADCAST, WM_SYSCOMMAND, SC_MONITORPOWER, 1);
Turn on:
PostMessage(HWND_BROADCAST, WM_SYSCOMMAND, SC_MONITORPOWER, -1);
0 Comments.