RadAjaxManager Online Help Incorrect

4 posts, 1 answers
  1. Konrad
    Konrad avatar
    21 posts
    Member since:
    Sep 2008

    Posted 30 Oct 2008 Link to this post

    I am a C# guy, but I am working on a VB (sigh) project at the moment
    and I was trying to follow the code example in the online help (http://www.telerik.com/help/aspnet-ajax/ajax-manager-proxy.html)  for adding a server-side event handler in a page that points to a master page with a RadAjaxManager. 

    The example is:
    protected void Page_Load(object sender, EventArgs e)
       RadAjaxManager manager = RadAjaxManager.GetCurrent(Page);
       manager.ClientEvents.OnRequestStart =
       manager.ClientEvents.OnResponseEnd =
       manager.AjaxRequest +=
     new RadAjaxControl.AjaxRequestDelegate(manager_AjaxRequest);

    Protected Sub Page_Load(ByVal sender As Object, ByVal e As EventArgs)
    Dim manager As RadAjaxManager = RadAjaxManager.GetCurrent(Page)
    manager.ClientEvents.OnRequestStart =
    manager.ClientEvents.OnResponseEnd = "onResponseEnd"
    manager.AjaxRequest += New RadAjaxControl.AjaxRequestDelegate(manager_AjaxRequest)
    End Sub

    The C# code works fine, but I really struggled to get the VB code working.
    No once again I'm not very famialiar with .NET VB code so I'm not sure if it is just something in my project but I doubt it.

    The code that finally compiled was as follows:

    Dim radAjaxManager As RadAjaxManager = radAjaxManager.GetCurrent(Page)
            radAjaxManager.ClientEvents.OnRequestStart = "onRequestStart"
            radAjaxManager.ClientEvents.OnResponseEnd = "onResponseEnd"
    AddHandler radAjaxManager.AjaxRequest, AddressOf radAjaxManager_AjaxRequest

    I hope this helps someone else out that might run into the same problem. ;)

    EDIT: I forgot to mention that I am currently using/testing 2008 Q3 1016 Beta

  2. Answer
    Sebastian avatar
    9934 posts

    Posted 03 Nov 2008 Link to this post

    Hello Konrad,

    Thank you for the remark - it is right on target! The VB.NET section of the help topic will be updated for the next version of the documentation. I updated your Telerik points for the involvement.

    Best regards,
    the Telerik team

    Check out Telerik Trainer, the state of the art learning tool for Telerik products.
  3. DevCraft R3 2016 release webinar banner
  4. Wired_Nerve
    Wired_Nerve avatar
    163 posts
    Member since:
    Oct 2007

    Posted 23 Feb 2009 Link to this post

    I am trying this in C# but I am getting a error from Visual Studio 2008, any ideas on this:

    In the line:
    manager.AjaxRequest += new RadAjaxControl.AjaxRequestDelegate(manager_AjaxRequest); 

    the words manager_AjaxRequest are underlined in RED with the tooltip and error message:
    THe name 'manager_AjaxRequest' does not exist in the current context...

    any ideas?

  5. Iana Tsolova
    Iana Tsolova avatar
    3388 posts

    Posted 25 Feb 2009 Link to this post

    Hi Warren,

    Try adding the below method to your code:

    protected void manager_AjaxRequest(object sender, Telerik.Web.UI.AjaxRequestEventArgs e)  
        //handle the ajax request here.   

    I hope this helps.

    Kind regards,
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Check out the tips for optimizing your support resource searches.
Back to Top