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

How to clear RadAsyncUpload files?

2 Answers 495 Views
AsyncUpload
This is a migrated thread and some comments may be shown as answers.
Lenny_shp
Top achievements
Rank 2
Lenny_shp asked on 24 Sep 2010, 09:26 PM

how to clear RadAsyncUpload files which is hosted in Jquery UI dialog on clientside?

 

        // clears the radasync upload

        function ClearFileInput() {

            var upload = $find("<%= rauMailingDocument.ClientID %>");           

            if (upload._uploadedFiles.length > 0) {

                Array.removeAt(upload._uploadedFiles, 0);

                upload.deleteFileInputAt(0);

                upload.updateClientState();

            }  

        }

Edit:  Update, the above seems to work, is that the preferred method?

2 Answers, 1 is accepted

Sort by
0
Peter
Telerik team
answered on 30 Sep 2010, 07:30 AM
Hello Lenny_shp,

It depends what exactly you want to achieve. You can also try using the upload.clearFileInputAt(0).


Peter
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
0
Esteban
Top achievements
Rank 1
answered on 01 May 2012, 08:33 PM
This worked for me. I inserted the jquery below in a close window function. I have the radasyncupload control in a radwindow

$("input[name=RowRemove]").each(function() {
      $(this).click();
});
Tags
AsyncUpload
Asked by
Lenny_shp
Top achievements
Rank 2
Answers by
Peter
Telerik team
Esteban
Top achievements
Rank 1
Share this question
or