Share via


Notification.BalloonChanged Event

Occurs when a message balloon is displayed or hidden.

Namespace: Microsoft.WindowsCE.Forms
Assembly: Microsoft.WindowsCE.Forms (in microsoft.windowsce.forms.dll)

Syntax

'Declaration
Public Event BalloonChanged As BalloonChangedEventHandler
'Usage
Dim instance As Notification
Dim handler As BalloonChangedEventHandler

AddHandler instance.BalloonChanged, handler
public event BalloonChangedEventHandler BalloonChanged
public:
event BalloonChangedEventHandler^ BalloonChanged {
    void add (BalloonChangedEventHandler^ value);
    void remove (BalloonChangedEventHandler^ value);
}
/** @event */
public void add_BalloonChanged (BalloonChangedEventHandler value)

/** @event */
public void remove_BalloonChanged (BalloonChangedEventHandler value)
In JScript, you can handle the events defined by a class, but you cannot define your own.
Not applicable.

Remarks

This event occurs whenever you set the Visible property.

For more information about handling events, see Consuming Events.

Example

The following code example demonstrates using this event to determine whenever a notification is created. This code example is part of a larger example provided for the Notification class.

' You can use the BalloonChanged event
' created by tracking each time the notification is made visible.
Private Sub OnBalloonChanged(obj As Object, _
  balevent As BalloonChangedEventArgs) Handles Notification1.BalloonChanged
   If balevent.Visible = True Then
    ' You can add code here to add 
    ' functionality such as user interface 
    ' changes that should occur when
    ' the notification is displayed.
   End If
End Sub
// You can use the BalloonChanged event
// created by tracking each time the notification is made visible.
private void OnBalloonChanged(object obj, BalloonChangedEventArgs balevent)
{
    if (balevent.Visible == true)
    {
        // You can add code here to add 
        // functionality such as user interface 
        // changes that should occur when
        // the notification is displayed.
    }

}

Platforms

Windows Mobile for Pocket PC

The Microsoft .NET Framework 3.0 is supported on Windows Vista, Microsoft Windows XP SP2, and Windows Server 2003 SP1.

Version Information

.NET Compact Framework

Supported in: 2.0

See Also

Reference

Notification Class
Notification Members
Microsoft.WindowsCE.Forms Namespace