Ticket T440329
Visible to All Users

New Web UI - How to customize the popup window so that it appears in the center instead of sliding from the right

created 8 years ago

Hello,

I have a quick question regarding popups in new ui. As default they open sliding from the right but when opening a lookupedit the popup is shown in middle. Is there a setting to toggle the behavior in application model? I tried setting the popupcontrol settings with a controller but they are overridden.

Answers approved by DevExpress Support

created 8 years ago (modified 8 years ago)

Hello Grigoris,

You can change the XafPopupWindowControl.ShowPopupMode and CustomizePopupWindowSizeEventArgs.ShowPopupMode properties in code to change this behavior. The former property affects all popup windows, the latter - a particular one. Please refer to the How to: Adjust the Size and Style of Pop up Dialogs in ASP.NET Applications topic for additional information. Let me know if you need further assistance.

    Comments (3)
    GT GT
    Grigoris Tsolakidis 8 years ago

      Setting the ShowPopupMode in the CustomizeSizeEvent does not work. The opened popup is still sliding.

      On frame assigned in a custom controller i wrote

      ((BaseXafPage)WebWindow.CurrentRequestPage).XafPopupWindowControl.CustomizePopupWindowSize +=
                      this.XafPopupWindowControlCustomizePopupWindowSize;

      and on the same above method

      ((BaseXafPage)WebWindow.CurrentRequestPage).XafPopupWindowControl.CustomizePopupWindowSize -=
                      this.XafPopupWindowControlCustomizePopupWindowSize;

      e.ShowPopupMode = ShowPopupMode.Centered;
      e.Height = Unit.Percentage(50);
      e.Width = Unit.Percentage(50);

      My method gets called as it should and the popup is the correct one (checked both popupview and parent frame) but no changes in the popup behavior.

      GT GT
      Grigoris Tsolakidis 8 years ago

        Disregard my last comment. XafPopupWindowControlCustomizePopupWindowSize method was missing the e.Handled = true statement. It is working now.

        Thank you

        Anatol (DevExpress) 8 years ago

          Great! Please do not hesitate to contact us if you need further assistance.

          Disclaimer: The information provided on DevExpress.com and affiliated web properties (including the DevExpress Support Center) is provided "as is" without warranty of any kind. Developer Express Inc disclaims all warranties, either express or implied, including the warranties of merchantability and fitness for a particular purpose. Please refer to the DevExpress.com Website Terms of Use for more information in this regard.

          Confidential Information: Developer Express Inc does not wish to receive, will not act to procure, nor will it solicit, confidential or proprietary materials and information from you through the DevExpress Support Center or its web properties. Any and all materials or information divulged during chats, email communications, online discussions, Support Center tickets, or made available to Developer Express Inc in any manner will be deemed NOT to be confidential by Developer Express Inc. Please refer to the DevExpress.com Website Terms of Use for more information in this regard.