Skip to main content

DXWindow

  • 2 minutes to read

DXWindow_Logo

DXWindow and DXDialog are designed to bring the popup windows functionality right to your web application powered by Silverlight.

#DXWindow Overview

DXWindow represents a popup window that can be filled with different visual elements. It is represented by the DXWindow object.

window_Icon_Bitmap

To specify the DXWindow's icon, use the DXWindow.Icon property. You can also specify a window's title via the Title property. In addition to image or textblock, any visual element can be displayed using these properties.

#Size and Location

DXWindow's position can be specified via the Left and Top properties. You can also specify whether the window should be shown at the position of the last closed window or not using the KeepPosition property. If the property is set to true, the Left and Top properties' values are reset with previous position coordinates.

You can specify whether an end-user is allowed to change DXWindow's size or not using the DXWindow.IsSizable property.

#Showing and Hiding

DXWindow can be displayed in either normal or modal modes. When a window is displayed in modal mode, it retains input focus while open. An end-user cannot switch to another window until this window is closed. To show DXWindow in modal mode, use the ShowDialog method. To show it in normal mode, use the Show method. You can obtain whether the window is shown in modal mode via the IsModal property.

To hide DXWindow, use the Hide method. All currently opened windows can be hidden via the HideAllWindows static method.

After DXWindow has been shown, the Opened event fires. When the window is about to be closed, the Closing event fires, allowing you to prevent the window from being closed. After the window is closed, the Closed event fires.

To make the window's appearance and disappearance more eye-catching, you can specify an animation for DXWindow. One way to do this is to choose one of the built-in animation types and specify it via the DXWindow.AnimationType property. Alternatively, you can create custom animations for a window's appearance and disappearance, and specify them using the DXWindow.ShowAnimation and DXWindow.HideAnimation properties respectively. In this instance, set the DXWindow.AnimationType property to WindowAnimationType.Custom.

#Examples