Opwn RAD Window with RAD PageView?

2 posts, 0 answers
  1. Craig Mellon
    Craig Mellon avatar
    53 posts
    Member since:
    May 2005

    Posted 22 Jul 2011 Link to this post

    I dropped an asp button within a RAD PageView control, on button click in code behind I call javascript to open the RAD Window...like this:

    Protected Sub Button1_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles Button1.Click
      Dim strScript As String = "<script language='javascript' type='text/javascript'>Sys.Application.add_load(ShowWindow);</script>"
      Page.ClientScript.RegisterStartupScript(Me.GetType, "ShowWindow", strScript)
    End Sub

    function ShowWindow() {
      var manager = GetRadWindowManager();
      var window1 = manager.GetWindowByName("SaveSiteNoteWindow");
      window1.show(null, "SaveSiteNoteWindow");

    I use this method in other scenerios and it works perfect, as soon as I drop the button within the RAD PageView control nothing happens upon button click.

    Please advise.


  2. Marin Bratanov
    Marin Bratanov avatar
    3907 posts

    Posted 25 Jul 2011 Link to this post

    Hello Craig,

      Your code seems correct and is working fine on my end - I am attaching the page I used to test with as a reference and you can find a video I recorded here: http://screencast.com/t/WLIdolzgV.

    On a side note - please make sure that you do not already have an update panel in the multipage, as the ClientScript's RegisterStartupScript may not always work in an ajaxified scenario. For this purpose I recommend the static ScriptManager's RegisterStartupScript method, as shown in this help article: http://www.telerik.com/help/aspnet-ajax/radwindow-troubleshooting-javascript-from-server-side.html.

    Please also note that the RadWindow's show() method does not take any arguments, as in my page.

    Please also refer to your other thread, related to this matter: Ticket ID: 432721, 'Error: Unable to get value of the property 'GetWindowByName': object is null or undefined' for more tips on the possible origin of such an issue.

      If you are still unable to resolve this please modify my page accordingly or post a list with the steps needed to reproduce it with my page so that we can give you a more relevant answer.

    Kind regards,
    the Telerik team

    Register for the Q2 2011 What's New Webinar Week. Mark your calendar for the week starting July 18th and book your seat for a walk through of all the exciting stuff we will ship with the new release!

Back to Top