I have a MasterPage with the RadAjaxManager, so in my sub-pages, I have
a RadAjaxManagerProxy. But it doesn't seem there is
ClientEvents-OnRequestStart for the proxy. I'm trying to do this in the
proxy:
ClientEvents-OnRequestStart="CenterElementOnScreen(document.getElementById('RadAjaxLoadingPanel1'));"
Is there a way to achieve this?
ClientEvents-OnRequestStart="CenterElementOnScreen(document.getElementById('RadAjaxLoadingPanel1'));"
Is there a way to achieve this?
6 Answers, 1 is accepted
0
Accepted

Vladimir
Top achievements
Rank 1
answered on 26 Apr 2008, 09:11 AM
You can access RadAjaxManager via GetCurrent(Page) static method and add desired client-side event directly to the manager. RadAjaxManagerProxy is just a storage for ajax settings.
0

Ryan Means
Top achievements
Rank 1
answered on 28 Jan 2009, 04:03 PM
It looks like you have to do this in the Page OnInit event. I tried it in the Page Load event and it did not work.
protected override void OnInit(EventArgs e) |
{ |
RadAjaxManager.GetCurrent(this.Page).ClientEvents.OnRequestStart = "searchRequestStart"; |
RadAjaxManager.GetCurrent(this.Page).ClientEvents.OnResponseEnd = "searchRequestEnd"; |
base.OnInit(e); |
} |
0
Hi Ryan,
Generally speaking, both client-side event can be attached either in the OnInit or OnLoad handler of the page. Can you please verify that you are using the latest release 2008.3.1314 of RadControls for ASP.NET AJAX in your project? If the problem persists, please paste your page definition in this thread in order to examine your complete code logic and research the matter further.
Best regards,
the Telerik team
Check out Telerik Trainer, the state of the art learning tool for Telerik products.
0

Valera
Top achievements
Rank 1
answered on 18 Aug 2009, 07:31 PM
What if I have this situation:
Master Page - has AjaxManager along with onEventStart="AjaxStart" and onEventEnd="AjaxEnd" events.
Content Page - has AjaxManagerProxy, I would like to have another set of onEventStart and onEventEnd events, but at the same time I don't want to overwrite nor replace original ones (from Master Page).
How do I achieve this functionality?
Master Page - has AjaxManager along with onEventStart="AjaxStart" and onEventEnd="AjaxEnd" events.
Content Page - has AjaxManagerProxy, I would like to have another set of onEventStart and onEventEnd events, but at the same time I don't want to overwrite nor replace original ones (from Master Page).
How do I achieve this functionality?
0
Hello Valerij,
RadAjaxManagerProxy may look like a separate control, but it is not. It just passes some AjaxSettings to the main RadAjaxManager control. So there can't be separate event handlers for the proxy.
What you can do is check the event arguments when the event is fired and depending on them, execute a specific part of the handler:
http://www.telerik.com/help/aspnet-ajax/ajxonrequeststart.html
Sincerely yours,
Dimo
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.
RadAjaxManagerProxy may look like a separate control, but it is not. It just passes some AjaxSettings to the main RadAjaxManager control. So there can't be separate event handlers for the proxy.
What you can do is check the event arguments when the event is fired and depending on them, execute a specific part of the handler:
http://www.telerik.com/help/aspnet-ajax/ajxonrequeststart.html
Sincerely yours,
Dimo
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.
0

Roger
Top achievements
Rank 1
answered on 27 Jul 2010, 01:29 AM
Hi,
I am using version 2010.1.415.35 but the reasoning still applies. The reason I am using this thread is that it came up first on Google so will be the one most watched and I had a similar problem to bemara57. I wanted to centre the loading image in the centre of the screen but I was using mast/content pages and a RadAjaxManagerProxy control on the content page (which doesn't have client events).
The suggested method is to use (in the content page):
however I was getting page.init errors.
So I used (in the content page, where RadAjaxMaster is the id of the RadAjaxManager in the master page):
and everything works fine. Hope this helps someone else.
Regards
I am using version 2010.1.415.35 but the reasoning still applies. The reason I am using this thread is that it came up first on Google so will be the one most watched and I had a similar problem to bemara57. I wanted to centre the loading image in the centre of the screen but I was using mast/content pages and a RadAjaxManagerProxy control on the content page (which doesn't have client events).
The suggested method is to use (in the content page):
Dim
manager
As
RadAjaxManager = RadAjaxManager.GetCurrent(Page)
manager.ClientEvents.OnRequestStart =
"centerLoadingPanel"
however I was getting page.init errors.
So I used (in the content page, where RadAjaxMaster is the id of the RadAjaxManager in the master page):
Dim
ajaxmanager
As
RadAjaxManager =
CType
(Master.FindControl(
"RadAjaxMaster"
), RadAjaxManager)
ajaxmanager.ClientEvents.OnRequestStart =
"centerLoadingPanel"
and everything works fine. Hope this helps someone else.
Regards