Skip to main content
A newer version of this page is available. .

SplashScreenManager.ShowOverlayForm(Control, OverlayWindowOptions) Method

Shows an Overlay Form over the specified control using the specified options.

Namespace: DevExpress.XtraSplashScreen

Assembly: DevExpress.XtraEditors.v18.2.dll

Declaration

public static IOverlaySplashScreenHandle ShowOverlayForm(
    Control owner,
    OverlayWindowOptions options
)

Parameters

Name Type Description
owner Control

A Control that should be overlapped by an Overlay Form.

options DevExpress.XtraSplashScreen.OverlayWindowOptions

An OverlayWindowOptions object that specifies the Overlay Form options, such as the loading image, fade animation and colors.

Returns

Type Description
DevExpress.XtraSplashScreen.IOverlaySplashScreenHandle

An IOverlaySplashScreenHandle object that specifies a handle for the shown Overlay Form, that is used to close the Overlay Form.

Remarks

Call the ShowOverlayForm to show an Overlay Form over the owner control using the specified options. The OverlayWindowOptions include the following:

  • BackColor—Overlay Form’s back color;
  • CustomPainter—an IOverlayWindowPainter object that performs the Overlay Form’s custom draw;
  • FadeIn—enables/disables the fade in animation;
  • FadeOut—enables/disables the fade out animation;
  • ForeColor—Overlay Form’s fore color;
  • Image—loading image shown rotating in the Overlay Form’s center;
  • Opacity—Overlay Form’s transparency level. 0 corresponds to the total transparency, 1 - to the normal state.

You can omit any of the options by passing null (Nothing in VB), and the default value will be used instead.

The ShowOverlayForm method returns an IOverlaySplashScreenHandle object. You should pass this handle to the SplashScreenManager.CloseOverlayForm method to close the opened Overlay Form.


using DevExpress.XtraSplashScreen;
//... 
bool useFadeIn = false;
bool useFadeOut = false;
Color backColor = Color.Red;
Color foreColor = Color.Black;
double opacity = 0.5;
Image waitImage = Image.FromFile("D://image.bmp");
OverlayWindowOptions options = new OverlayWindowOptions(
    useFadeIn,
    useFadeOut,
    backColor,
    foreColor,
    opacity,
    waitImage);
IOverlaySplashScreenHandle handle = SplashScreenManager.ShowOverlayForm(theRequiredControl, options);
See Also