Kendo UI multiple files upload not working

2 posts, 0 answers
  1. Srinivasa Rao
    Srinivasa Rao avatar
    2 posts
    Member since:
    Mar 2015

    Posted 28 Apr 2015 Link to this post

    I am using a Kendo File Upload control to upload multiple files. Only few of the files are getting uploaded (especially first and last) or some random ones. Is there any solution for this ?

    Index.cshtml :<input name="files" id="files" type="file" multiple="multiple" />

    JS File :$("#files").kendoUpload
    ({
    async: {
    saveUrl: "/Controller/GetUserUploadedFiles",
    removeUrl: "/Controller/Remove",
    autoUpload: false,
    allowmultiple: true,
    batch: true
    },
    select: function (e) {
    onSelect(e);
    },
    success: function (e) {
    },
    error: function (e) {
    }
    });

    //Controller Method

    [HttpPost]
    public void GetUserUploadedFiles(IEnumerable<HttpPostedFileBase> files)
    {
    //Custom logic here
    }

    Also, it would be great if i can get all the files as Enumerable in one controller method call rather than having it called multiple times for multiple files.Is there anything i am missing or doing wrong ?

    Thanks, Srini

  2. Dimiter Madjarov
    Admin
    Dimiter Madjarov avatar
    2153 posts

    Posted 29 Apr 2015 Link to this post

    Hello Srinivasa,

    We are not aware of such issue. Please send us an isolated runnable example that demonstrates the case, so we could inspect it locally and provide assistance.

    Regarding the second question, the async.batch only applies to files selected at the same time. Those selected one after the other would still be posted in separate requests.

    Regards,
    Dimiter Madjarov
    Telerik
     
    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
     
  3. Kendo UI is VS 2017 Ready
Back to Top