Link to home
Start Free TrialLog in
Avatar of Wigging
WiggingFlag for United States of America

asked on

telerik radwindow issue

Im trying to open a window through serverside code but it wont open....what am i missing?

  If bladeDiscount > 0 Then
                      Dim window6 As New RadWindow()
            window6.NavigateUrl = "http://www.google.com"
            window6.VisibleOnPageLoad = True
            window6.Width = 500
            window6.Height = 300
            Me.Controls.Add(window6)

        Else
            If Session("bladeDiscount") = "YES" Then
                order.ResetDiscounts(strSite)
                Session("bladeDiscount") = ""

                Dim message2 As String = "Sorry, the quantity of your blade order no longer qualifies for a discount."
                ClientScript.RegisterStartupScript(Me.GetType, "jsMessage", "alert('" & message2 & "');", True)
            End If
        End If

Avatar of edemcs
edemcs
Flag of United States of America image

Is this done within an UpdatePanel?  If so, make sure that the UpdatePanel is refreshing after the callback
Avatar of Wigging

ASKER

no i dont have updatepanel?   do i have to add one?
No, you don't need to.  You have to add the window you create to the RadWindowsManager.Windows collection.  Do you have that on your page?
Avatar of Wigging

ASKER

yes, I have this...what else am i missing?
                                <telerik:RadWindowManager ID="RadWindowManager1"
                                                ShowContentDuringLoad="False"
                                                AutoSize="True"  
                                                VisibleStatusbar="False"
                                                ReloadOnShow="True"  
                                                runat="server"
                                                Opacity="99"  
                                                BehaviorsAutoSize="true"
                                                Skin="Sunset"
                                                EnableShadow="True" >
                                                <Windows>
                                                    <telerik:RadWindow ID="RadWindow2" runat="server" Behaviors="Close" OnClientClose="OnClientClose"
                                                        NavigateUrl="DialogCS2.aspx">
                                                    </telerik:RadWindow>
                                           
                                                    <telerik:RadWindow ID="RadWindow6" runat="server" AutoSize="True"
                                                        EnableShadow="True" NavigateUrl="dialogalternateitem.aspx" Opacity="99"
                                                        ReloadOnShow="True" ShowContentDuringLoad="False" Skin="Sunset"
                                                        style="display:none;" VisibleStatusbar="False">
                                                    </telerik:RadWindow>
                                           
                                                </Windows>
                                            </telerik:RadWindowManager>
If you have it on the ASPX side, it would be redudent to add it in the code-behind.  Your style for the window is display:none which will hide it.  Remove that style and set the visibility of the window in the code-behind.  Let me get you an example.
ASKER CERTIFIED SOLUTION
Avatar of edemcs
edemcs
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial