Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

turn on the screen

Posted on 2009-04-14
2
Medium Priority
?
257 Views
Last Modified: 2012-05-06
Hi experts

I have a fairly simple question  (I think)  :o)

I have a computer running my VB 2005 app. The computer is set to turn off its monitor after 10 minutes. (In control panel, power settings)
Now I want my app, at a given time, to be able to tell the pc to turn on the monitor again.
I have thought about doing some simulated mouse move but don't know how

Does anybody know how to solve my problem

Thanks in advance
0
Comment
Question by:liversen
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 23

Accepted Solution

by:
ComputerTechie earned 1500 total points
ID: 24141299
0
 
LVL 1

Author Closing Comment

by:liversen
ID: 31570075
Ended up using mouse move. Seemed most elegant.
Thanks for the help.
My code:

'Declaration
Private Declare Sub mouse_event Lib "user32" (ByVal dwFlags As Long, ByVal dx As Long, ByVal dy As Long, ByVal cButtons As Long, ByVal dwExtraInfo As Long)

'In a method:
MOUSEEVENTF_MOVE = &H1
mouse_event MOUSEEVENTF_MOVE, 25, 25, 0, 0
0

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Most everyone who has done any programming in VB6 knows that you can do something in code like Debug.Print MyVar and that when the program runs from the IDE, the value of MyVar will be displayed in the Immediate Window. Less well known is Debug.Asse…
Article by: Martin
Here are a few simple, working, games that you can use as-is or as the basis for your own games. Tic-Tac-Toe This is one of the simplest of all games.   The game allows for a choice of who goes first and keeps track of the number of wins for…
This video Micro Tutorial explains how to clone a hard drive using a commercial software product for Windows systems called Casper from Future Systems Solutions (FSS). Cloning makes an exact, complete copy of one hard disk drive (HDD) onto another d…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…
Suggested Courses

688 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question