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

MVC Upload File Select Order

1 Answer 161 Views
Upload
This is a migrated thread and some comments may be shown as answers.
Luis
Top achievements
Rank 1
Luis asked on 03 Apr 2015, 04:19 PM
I need to know the order in what the files were selected in an upload widget that is set to ASYNC, Allow multi and auto upload true. Any ideas how this can accomplish?

1 Answer, 1 is accepted

Sort by
0
Dimiter Madjarov
Telerik team
answered on 06 Apr 2015, 06:57 AM

Hello Luis,

A sample approach would be to send metadata to the save handler using the upload widget client side event. In the current case you could send the index of the file in the file list.
E.g.

function upload(e) {
    var uid = e.files[0].uid;
    var file = this.wrapper.find(".k-file[data-uid='" + uid + "']");
    var index = file.index();
 
    e.data = {
        index: index
    }
}

Regards,
Dimiter Madjarov
Telerik
 

See What's Next in App Development. Register for TelerikNEXT.

 
Tags
Upload
Asked by
Luis
Top achievements
Rank 1
Answers by
Dimiter Madjarov
Telerik team
Share this question
or