Running a task at a specific time.

  • Thread starter Thread starter ajit goel
  • Start date Start date
A

ajit goel

Hi everyone;

We have a requirement to run an event at 12.00 pm. We have used the
System.Windows.Timer object to set the interval for the timer
object(to run the event at 12.00 pm).

But if the Pocket PC goes into the "sleep" mode, the event does not
fire.

The Power management in the control panel should not be changed from
the set system default values.

Proposed solution: Register an event on the application's main
thread.The event will be activated when the application's main thread
gets started.

How can this requirment be met??.

I would appreciate all your help\comments.

Configuration:

Compact Framework.
Windows CE 4.2

Kind Regards;
Ajit Goel
 
You can register an application with the CeRunAppAtTime API call. This will
wake up the device if it is off. If your app is to be left running on the
device the best strategy is to create a small exe which simply sends a
windows message, re-registers itself with CeRunAppAtTime so that it runs the
next day and then exits. You can then use a MessageWindow in your app to
receive this message and raise a managed event.

Peter

--
Peter Foot
Windows Embedded MVP
www.inthehand.com | www.opennetcf.org

Do have an opinion on the effectiveness of Microsoft Windows Mobile and
Embedded newsgroups? Let us know!
https://www.windowsembeddedeval.com/community/newsgroups
 
Back
Top