This is a migrated thread and some comments may be shown as answers.

RadUpload and AjaxManagerProxy

3 Answers 79 Views
Upload (Obsolete)
This is a migrated thread and some comments may be shown as answers.
Robert
Top achievements
Rank 1
Robert asked on 17 Oct 2008, 08:49 AM
Hi,

I've found some posts in this forum on how to temporarily disable ajax
when clicking the submit button to upload a file.
Unfortunately I can't set the "onrequestsart" property on RadAjaxmanager.
How can I work around this issue?

Best regards,
Robert

3 Answers, 1 is accepted

Sort by
0
Veselin Vasilev
Telerik team
answered on 17 Oct 2008, 08:55 AM
Hi Robert,

The property is: ClientEvents-OnRequestStart

Here is a sample code:

<telerik:RadAjaxManager ID="RadAjaxManager1"  
    runat="server"  
    ClientEvents-OnRequestStart="onRequestStartHandler"
</telerik:RadAjaxManager> 

You can set it only on the RadAjaxManager, not in the RadAjaxManagerProxy.

Best wishes,
Veselin Vasilev
the Telerik team

Check out Telerik Trainer, the state of the art learning tool for Telerik products.
0
Robert
Top achievements
Rank 1
answered on 17 Oct 2008, 11:39 AM
Hi Veselin,

when I set this property in the ajax manager within the masterpage will it
disable ajax on all requests? I only want to disable ajax, when the uploda
button (which resides in the content page) is clicked.

Best regards,
Robert
0
Veselin Vasilev
Telerik team
answered on 20 Oct 2008, 12:51 PM
Hi Robert,

Here is what you can do:

In the content page declare a global javascript variable:

var canUpload = false

Subscribe to the OnClientClick event of the button - it fires before the postback. In that event set the canUpload variable to true. Now, on the onRequestStart event handler stop the ajax if the canUpload variable is true.

I hope this helps.

Best wishes,
Veselin Vasilev
the Telerik team

Check out Telerik Trainer, the state of the art learning tool for Telerik products.
Tags
Upload (Obsolete)
Asked by
Robert
Top achievements
Rank 1
Answers by
Veselin Vasilev
Telerik team
Robert
Top achievements
Rank 1
Share this question
or