473,809 Members | 2,804 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Monitor Message

Is there a way to receive a message when the monitor turns on/off?
Such as in wndProc? I want to run some code after the monitor turns
back on. And when the mouse moves or the keyboard moves it turns on
the monitor so i will never know when the monitor turns on unless a
message gets fired back to me. I use sendMessage((in t), this.handle,
WM_SYSCOMMAND, SC_MONITORPOWER , MONITOR_OFF) to turn off the monitor.
Maybe can i use same constant in a event handler such as wndProc?

Thanks for any help.

Jan 5 '06 #1
2 1770
Hi,

Not sure ( I bet not) that you can get a notification when the user turn off
the monitor. Another thing is when the system turn it off to preserve energy
--
Ignacio Machin,
ignacio.machin AT dot.state.fl.us
Florida Department Of Transportation

"Dave" <dc*****@gmail. com> wrote in message
news:11******** *************@f 14g2000cwb.goog legroups.com...
Is there a way to receive a message when the monitor turns on/off?
Such as in wndProc? I want to run some code after the monitor turns
back on. And when the mouse moves or the keyboard moves it turns on
the monitor so i will never know when the monitor turns on unless a
message gets fired back to me. I use sendMessage((in t), this.handle,
WM_SYSCOMMAND, SC_MONITORPOWER , MONITOR_OFF) to turn off the monitor.
Maybe can i use same constant in a event handler such as wndProc?

Thanks for any help.

Jan 5 '06 #2
Dave,

I'm not expert in this area, but I think the new PnP monitors (which are
almost all monitors nowadays) send this information to the display driver. I
believe if such notification is available it will be part of DDK. Probably
you should ask your question in related newsgroups.
--

Stoitcho Goutsev (100)

"Dave" <dc*****@gmail. com> wrote in message
news:11******** *************@f 14g2000cwb.goog legroups.com...
Is there a way to receive a message when the monitor turns on/off?
Such as in wndProc? I want to run some code after the monitor turns
back on. And when the mouse moves or the keyboard moves it turns on
the monitor so i will never know when the monitor turns on unless a
message gets fired back to me. I use sendMessage((in t), this.handle,
WM_SYSCOMMAND, SC_MONITORPOWER , MONITOR_OFF) to turn off the monitor.
Maybe can i use same constant in a event handler such as wndProc?

Thanks for any help.

Jan 5 '06 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

10
30459
by: KJM | last post by:
How can I detect if the user has dual monitors and then how do I control which monitor a form is displayed on. Currently my forms always come up on my right monitor. What if I want to have it always display on my left one? Thanks Ken
10
11625
by: santiago538 | last post by:
Hi, Is there any way to specify which monitor a Window.open() will launch a new browser window in on systems with more than one display. It would only need to work with Mozilla browsers, and not IE. Thanks!
3
7839
by: hikums | last post by:
I dropped the db2detaildeadlock event monitor without flushing the events that were full hoping dropping it will clear the messages also. I now understand this is a default monitor that I should not dropped. Now there are "SEVERE" error messages occuring everyday -few times. What should I do to ensure these messages are not thrown. 2005-04-27-06.24.04.087962-240 I6572370C334 LEVEL: Warning PID : 17042 TID : 1 ...
4
3199
by: Charles Law | last post by:
I've been using monitors a bit lately (some of you may have heard ;-) ) and then up pop Manual and AutoResetEvents , and they look for all the world like the same thing. Are they interchangeable, or when should I use one over the other? TIA Charles
12
5278
by: Perecli Manole | last post by:
I am having some strange thread synchronization problems that require me to better understand the intricacies of Monitor.Wait/Pulse. I have 3 threads. Thread 1 does a Monitor.Wait in a SyncLock block protecting a resource. Thread 2 and 3 also have a SyncLock block protecting the same resource and after executing some code in their blocks they both do a Monitor.Pulse to hand of the locked resource back to thread 1. While thread 1 has...
10
1812
by: RobinS | last post by:
Hello to all, and happy new year! I have this application that someone wrote that I'm sort of checking out. The forms look fine in design mode, but when I run the application, it crops off the bottom of almost every form. I haven't figured out yet if there's a pattern to it. I compared two forms -- one that looks okay and one that gets cropped, and aside from the size and the accept button and the cancel button, their properties are...
1
3337
by: vijay.db | last post by:
Hi group, Have a problem with event monitor so my db2diag.log is getting filled like any thing.. Running DB2 V8.1 Fixpack 6 in AIX server. Created a event monitor and redirecting it's output to a file..getting error like
13
5980
by: Cross | last post by:
I am developing an application that will show movies. When you wach a movie, you do not want the Power Option "Turn off monitor" to be anabled. Is there anyway to fix this from VB.net? (note that I am not talking about the screen saver, that is something else). I'm very thankfull for answers, but plea, no guesses this time.
5
14819
by: jbenner | last post by:
I have opened a PMR for this with IBM, and am not asking for advice from the DB2 DBA community. I am posting this as an FYI that DB2 Health Monitor, even at the latest version of DB2, still can cause huge problems with slow connect times and heavy resource locking in high concurrency / high transaction volume environments. I have an OLTP with 30-90 transactions per second activity, and start of Health Monitor every 2 hours was crashing our...
0
10643
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10378
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
9200
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7664
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6881
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5690
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4333
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
3862
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
3015
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.