Radalert JS error when calling from Grid insert command

2 posts, 0 answers
  1. Web team
    Web team avatar
    57 posts
    Member since:
    Mar 2010

    Posted 27 Apr 2010 Link to this post

    I am calling radalert from the server side inside radgrid insertcommand.

    Here's my code:
    Page.ClientScript.RegisterStartupScript(GetType(), "key""<script type='text/javascript'>javascript:radalert('" + pMessage + "'); </script>"); 

    I am having javascript error saying parameter c, d and a are undefined.

    function GetRadWindowManager(){return Telerik.Web.UI.WindowManager.Manager; 
    }window.radalert=function(e,c,d,a){var b=GetRadWindowManager(); 
    return b.radalert(e,c,d,a); 

  2. Princy
    Princy avatar
    17421 posts
    Member since:
    Mar 2007

    Posted 27 Apr 2010 Link to this post

    Hello Arnold,

    The reason for the problem can be the RadWindowManager is still not rendered on the page when you call the radalert. The following KB article shows how to call radalert for different scenarios:
    Calling radalert from codebehind 

    Also checkout the blog post: Executing JavaScript function from server-side code

Back to Top