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

Open Rad Window From server side

2 Answers 169 Views
Window
This is a migrated thread and some comments may be shown as answers.
Albert
Top achievements
Rank 1
Albert asked on 26 Jan 2011, 01:31 PM
Hello ,

I wanted to open rad window when user clinked one of my menu item. Consider that menu item is "Product". Menu click event code is as follows:

protected void NavigationMenu_ItemClick(object sender, Telerik.Web.UI.RadMenuEventArgs e)
        {
            if (e.Item.Value == "Theme")
            {
                 
            }
            else if (e.Item.Text == "Product")
            {
                ScriptManager.RegisterStartupScript(this, GetType(), "openWin", "openWin();", true);            
            }
 
        }


And my JavaScript function is as follows :

function openWin() {
var oWnd = radopen("Product.aspx", "RadWindow1");
oWnd.moveTo(125, 60);
}

Now when I clicked on Produce menu I am getting following JavaScript error .


Error: b is undefined
Source File: http://localhost/Company/Telerik.Web.UI.WebResource.axd?_TSM_HiddenField_=RadScriptManager1_TSM&compress=1&_TSM_CombinedScripts_=%3b%3bSystem.Web.Extensions%2c+Version%3d4.0.0.0%2c+Culture%3dneutral%2c+PublicKeyToken%3d31bf3856ad364e35%3aen-US%3a8f393b2b-3315-402f-b504-cd6d2db001f6%3aea597d4b%3ab25378d2%3bTelerik.Web.UI%2c+Version%3d2010.3.1317.40%2c+Culture%3dneutral%2c+PublicKeyToken%3d121fae78165ba3d4%3aen-US%3a8fa155ef-f4b5-45a5-8081-4caa696cfcad%3a16e4e7cd%3af7645509%3a24ee1bba%3ae330518b%3a1e771326%3ac8618e41%3aa7e79140%3a874f8ea2%3a19620875%3af46195d3%3a490a9d4e%3abd8f85e4
Line: 8175

If any one knows how to solve this then please tell me.In short I want to open rad window from server side.

-Thanks

2 Answers, 1 is accepted

Sort by
0
Albert
Top achievements
Rank 1
answered on 26 Jan 2011, 01:34 PM
I have also tried to open window by following code : 


else if (e.Item.Text == "Product")
            {
                RadWindow1.VisibleOnPageLoad = true;            
            }

But some problems are there with code : 

1.Page is not being loaded in rad window .
2.At any menu click rad window is opening .
0
Shinu
Top achievements
Rank 2
answered on 27 Jan 2011, 01:19 PM
Hello,


I hope the following forum link will be of help in opening RadWindow from code.
Want to pop up window from server side



-Shinu.
Tags
Window
Asked by
Albert
Top achievements
Rank 1
Answers by
Albert
Top achievements
Rank 1
Shinu
Top achievements
Rank 2
Share this question
or