How to reset file upload input


In a form, I have the following input, to select a file to upload:

<input type="file" id="document_1" cam-variable-name="document_1" cam-variable-type="File" cam-max-filesize="11000000" />&nbsp;
<button ng-click="resetFileInput()">Cancel</button>

The resetFileInput method is:

$scope.resetFileInput = function () {
   console.log("Camunda variables:  ", camForm.variableManager.variables);

How could I reset the document_1 variable when the user clicks the ‘Cancel’ button?

Thanks in advance,

I found a solution using jQuery:

<button onclick="resetFileInput()">Cancel</button>
function resetFileInput() {


Thanks for posting your solution!