radopen on a button click

4 posts, 0 answers
  1. David
    David avatar
    81 posts
    Member since:
    May 2011

    Posted 06 Jun 2011 Link to this post

      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
  2. Shinu
    Shinu avatar
    17764 posts
    Member since:
    Mar 2007

    Posted 07 Jun 2011 Link to this post

    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.
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. David
    David avatar
    81 posts
    Member since:
    May 2011

    Posted 07 Jun 2011 Link to this post

    Thank you,

    Guess I was really tired yesterday to don't think about it.
  5. Jahabar
    Jahabar avatar
    1 posts
    Member since:
    Jul 2016

    Posted 17 Jul in reply to Shinu Link to this post

    Your post helped me.

    Thank you Shinu

Back to Top