0

hello frnds,i want to check if the computer is in sleep mode or not...Suppose my project is in normal state..I change the state to sleep mode,I want that now when the computer wakes from sleep mode,I want that my project is in minimized state..How to check dat?

I have searched on the google,But didnt find anything...

2
Contributors
2
Replies
3
Views
8 Years
Discussion Span
Last Post by mansi sharma
0
Imports Microsoft.Win32

Public Class Form1
    Public Sub New()
        MyBase.New()


        InitializeComponent()
        AddHandler SystemEvents.PowerModeChanged, _
        AddressOf SystemEvents_PowerModeChanged

    End Sub

    Private Sub SystemEvents_PowerModeChanged( _
    ByVal sender As Object, _
    ByVal e As PowerModeChangedEventArgs)
        MsgBox(e.Mode.ToString())
    End Sub

End Class

BUt event SystemEvents_PowerModeChange is not fire when i change the mode..can u help me!

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.