NotificationWindow.Close Method
Microsoft Silverlight will reach end of support after October 2021. Learn more.
Immediately closes the notification window.
Namespace: System.Windows
Assembly: System.Windows (in System.Windows.dll)
Syntax
'Declaration
Public Sub Close
public void Close()
Remarks
Calling Close closes the notification window immediately. The fade-out animation does not run in this case.
A typical design for the content area displayed in NotificationWindow would handle commands or events on a UI element that is intended to close the notification. Close is called from the handler logic for that element.
Calling Close or providing UI to invoke it is not always necessary for user scenarios. The notification will eventually time out/fade out per the durationInMilliseconds value passed for Show.
If you are sharing a NotificationWindow instance for all an application's notification, you may want to call Close immediately before attempting a new Show call. This avoids a possible no-op. For more information, see Show.
Version Information
Silverlight
Supported in: 5, 4
Platforms
For a list of the operating systems and browsers that are supported by Silverlight, see Supported Operating Systems and Browsers.