Skip to main content

ASPxPopupControlBase.ShowOnPageLoad Property

Gets or sets a value that specifies whether the window is automatically displayed when a client browser loads the page.

Namespace: DevExpress.Web

Assembly: DevExpress.Web.v22.1.dll


public virtual bool ShowOnPageLoad { get; set; }

Property Value

Type Default Description
Boolean false

true, if the window is displayed on the page load; otherwise, false.


The ShowOnPageLoad property can’t be changed during a callback.


For ASPxPopupControl only:

If the ASPxPopupControl.Windows collection is not empty, the ShowOnPageLoad property is not in effect, and cannot be used to specify a common page load behavior for all popup windows. In this case, use the PopupWindow.ShowOnPageLoad property of individual popup windows from the collection.


In this example, the client BringToFront method of an ASPxPopupControl is used to display the control's default window above other popup windows displayed on the page.

View Example

<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default.aspx.cs" Inherits="PopupControl_BringToFrontSample" %>

<%@ Register Assembly="DevExpress.Web.v13.1" Namespace="DevExpress.Web.ASPxEditors" TagPrefix="dxe" %>
<%@ Register Assembly="DevExpress.Web.v13.1" Namespace="DevExpress.Web.ASPxPopupControl" TagPrefix="dxpc" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "">
<html xmlns="">
<head runat="server">
    <title>Untitled Page</title>

    <script type="text/javascript">
        function BringWindow1ToFront() {
        function BringWindow2ToFront() {

    <form id="form1" runat="server">
                    <td width="250px">
                        <dxpc:ASPxPopupControl ID="pc1" ClientInstanceName="popupControl1" runat="server" 
                            HeaderText="Window1" ShowOnPageLoad="True" Top="10" Left="10" CloseAction="CloseButton">
                                <dxpc:PopupControlContentControl runat="server" />
                        <dxpc:ASPxPopupControl ID="pc2" ClientInstanceName="popupControl2" runat="server" 
                            HeaderText="Window2" ShowOnPageLoad="True" Top="20" Left="20" CloseAction="CloseButton">
                                <dxpc:PopupControlContentControl runat="server" />
                    <td valign="top">
                        <dxe:ASPxButton ID="btn1" runat="server" Text="Window1 to front" AutoPostBack="False">
                            <ClientSideEvents Click="BringWindow1ToFront" />
                    <td valign="top">
                        <dxe:ASPxButton ID="btn2" runat="server" Text="Window2 to front" AutoPostBack="False">
                            <ClientSideEvents Click="BringWindow2ToFront" />
See Also