getFiles

Retrieves the files that are currently selected.

Example

<input name="files" id="files" type="file" />
<button id="getFiles" class="k-button">Show selected files count</button>
<script>

  $(document).ready(function() {
    $("#files").kendoUpload();

    $("#getFiles").on('click', function(e){
      e.preventDefault();

      var upload = $("#files").data("kendoUpload"),
          files = upload.getFiles();

      alert("You have selected " + files.length  + " files");
      console.log(files);
    })
  });
</script>

Returns

Represents an Array collection of all currently selected files.

In this article
Not finding the help you need? Improve this article