Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / .NET Framework / New Users / July 2006

Tip: Looking for answers? Try searching our database.

Detecting Battery Backup Notification

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
EmmanuelE - 25 Jul 2006 23:25 GMT
I am setting up a couple of servers for an internal beta test of a web app.  
I want to implement a feature that would tell logged in users to log out
should a power failure occur (and the servers are running on UPS batteries).

Assuming I configure the Power Options so that "Notifications" are
broadcast, how do I detect those notifications in my web app?  I have search
high and low for what these "Notifications" are but cannot find anything.
Peter Ritchie [C# MVP] - 26 Jul 2006 21:22 GMT
Coding4Fun had a recent article about being "Power-aware" titled "You Can
Take It With You, Part 1" [1]

That article basically details how to use the SystemEvents.PowerModeChanged
[2]event.

[1] http://msdn.microsoft.com/coding4fun/inthebox/mobile1/default.aspx
[2]
http://msdn2.microsoft.com/en-us/library/microsoft.win32.systemevents.powermodec
hanged.aspx


Signature

http://www.peterRitchie.com/blog/
Microsoft MVP, Visual Developer - Visual C#

> I am setting up a couple of servers for an internal beta test of a web app.  
> I want to implement a feature that would tell logged in users to log out
[quoted text clipped - 3 lines]
> broadcast, how do I detect those notifications in my web app?  I have search
> high and low for what these "Notifications" are but cannot find anything.
EmmanuelE - 26 Jul 2006 21:55 GMT
I'm reading the MSDN help now (that's always an interesting exercise isn't
it!) to figure out how to write a user space service that will listen for
power change system events.

The article was very helpful.

Thanks!  I think I'm on my way to figuring this all out.

> Coding4Fun had a recent article about being "Power-aware" titled "You Can
> Take It With You, Part 1" [1]
[quoted text clipped - 13 lines]
> > broadcast, how do I detect those notifications in my web app?  I have search
> > high and low for what these "Notifications" are but cannot find anything.
Peter Ritchie [C# MVP] - 26 Jul 2006 22:05 GMT
Good to hear.  I didn't find the PowerModeChanged event docs very detailed.  
The article is a good adjunct.

Signature

Browse http://connect.microsoft.com/VisualStudio/feedback/ and vote.
http://www.peterRitchie.com/blog/
Microsoft MVP, Visual Developer - Visual C#

> I'm reading the MSDN help now (that's always an interesting exercise isn't
> it!) to figure out how to write a user space service that will listen for
[quoted text clipped - 21 lines]
> > > broadcast, how do I detect those notifications in my web app?  I have search
> > > high and low for what these "Notifications" are but cannot find anything.

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.