Raise Server RadTextBox_Load by Client Side

3 posts, 1 answers
  1. Roberto
    Roberto avatar
    6 posts
    Member since:
    May 2007

    Posted 01 Feb 2011 Link to this post

    Hi,

    I Need trigger Server event Load for RadTextbox without page postback, using client side javascript.
    I tried sender.raise_load(Sys.EventArgs.Empty); in javascript function from button click event, but not work.
    Any help is welcome.

    Thanks advanced.

    Roberto
  2. Answer
    Shinu
    Shinu avatar
    17764 posts
    Member since:
    Mar 2007

    Posted 02 Feb 2011 Link to this post

    Hello Roberto,

    You can make an ajaxRequest on the client Button Click and call the desired function from there.

    JavaScript:
    function OnClientClick()
      {
          var ajaxManager = $find("<%= RadAjaxManager1.ClientID %>");
          ajaxManager.ajaxRequest();
      }

    C#:
    protected void RadAjaxManager1_AjaxRequest(object sender, AjaxRequestEventArgs e)
       {
           doSomething();
       }
       protected void RadTextBox_Load(object sender, AjaxRequestEventArgs e)
       {
           doSomething();
       }
       public void doSomething()
       {
           // Do something
       }



    Thanks,
    Shinu.
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Roberto
    Roberto avatar
    6 posts
    Member since:
    May 2007

    Posted 02 Feb 2011 Link to this post

    thanks very much Shinu, works perfectly for what I need.

    Roberto.
Back to Top