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

radopen on a button click

3 Answers 566 Views
Button
This is a migrated thread and some comments may be shown as answers.
David
Top achievements
Rank 1
David asked on 06 Jun 2011, 09:29 PM
    HI,

Does it possible to open a window with a simple click on a rad button. It should be really easy to do, but I don't know how to do this. I tried, with the onClientClicked event, to call a radopen, but it didn't work. It seem that radopen is not defined. In fact, in javascript console (Chrome), the following error message appears:

  1. Uncaught ReferenceError: radopen is not defined
    1. (anonymous function)test.aspx:59

May someone help me please ?
Thank you

3 Answers, 1 is accepted

Sort by
0
Shinu
Top achievements
Rank 2
answered on 07 Jun 2011, 06:47 AM
Hello David,
Have you defined RadWindowManager on page? radopen() requires the RadWindowManager to exist on the page. Here is the full code that I tried.
aspx:
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
</head>
<body>
    <form id="form1" runat="server">
    <div>
       <asp:ScriptManager ID="ScriptManager1" runat="server">
       </asp:ScriptManager>
       <telerik:RadWindowManager ID="window1" runat="server" ReloadOnShow="true" OnClientClose="ClientClose">
       </telerik:RadWindowManager>
       <telerik:RadButton ID="RadBtn1" runat="server" Text="OpenRadWindow" OnClientClicked="OnClientClicked" AutoPostBack="false">
       </telerik:RadButton>
    </div>
    </form>
</body>
</html>
Javascript:
<script type="text/javascript">
    function OnClientClicked()
    {
       radopen("http://www.google.com", null);
    }
</script>

Thanks,
Shinu.
0
David
Top achievements
Rank 1
answered on 07 Jun 2011, 02:23 PM
Thank you,

Guess I was really tired yesterday to don't think about it.
0
Jahabar
Top achievements
Rank 1
answered on 18 Jul 2016, 03:45 AM

Your post helped me.

Thank you Shinu

Tags
Button
Asked by
David
Top achievements
Rank 1
Answers by
Shinu
Top achievements
Rank 2
David
Top achievements
Rank 1
Jahabar
Top achievements
Rank 1
Share this question
or