This is a migrated thread and some comments may be shown as answers.

RadWindow not opening from CodeBehind

1 Answer 85 Views
This is a migrated thread and some comments may be shown as answers.
Top achievements
Rank 1
Shawn asked on 10 May 2012, 09:26 PM
I am attempting to show a radWindow based on a combobox selection, and nothing is happening.

I have a radWindowManager on the page:

<telerik:RadWindowManager ID="RadWindowManager1" runat="server"

and the code behind is simply:

Protected Sub list_State_SelectedIndexChanged(sender As Object, e As Telerik.Web.UI.RadComboBoxSelectedIndexChangedEventArgs) Handles list_State.SelectedIndexChanged
        If list_State.SelectedValue = "NV" Then
            Dim url As String = String.Format("nevada-alert.aspx")
            Dim NewWindow As RadWindow = New RadWindow()
            NewWindow.ID = "win_ServiceState"
            NewWindow.Title = "Nevada is currently offline."
            NewWindow.Height = 330
            NewWindow.Width = 420
            NewWindow.ReloadOnShow = True
            NewWindow.Modal = True
            NewWindow.ShowContentDuringLoad = False
            NewWindow.KeepInScreenBounds = True
            NewWindow.VisibleOnPageLoad = True
            NewWindow.NavigateUrl = url
        End If
    End Sub

Shouldn't that be sufficient in launching the window?

1 Answer, 1 is accepted

Sort by
Marin Bratanov
Telerik team
answered on 14 May 2012, 02:07 PM
Hello Shawn,

Are you using AJAX in this page? It seems like the combo box performs an AJAX request that does not include the RadWindowManager in the response and thus the new RadWindow is not received by the browser. You can easily confirm this by either removing all asp update panels on the page, or setting the EnableAJAX property of the RadAjaxManager/panel to false, or by wrapping the window manager in an update panel with updateMode set to Conditional.

Kind regards,
the Telerik team
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
Asked by
Top achievements
Rank 1
Answers by
Marin Bratanov
Telerik team
Share this question