Question: how can I reset file input in IE, I used the following and it worked in chrome and FF but not IE 

`fileInputElement.value=""`

what's the alternative in IE ?

Answer: 
### SOLUTION

The following code worked for me with jQuery. It works in every browser and allows to preserve events and custom properties.

```
var $el = $(fileInputElement);
$el.wrap('<form>').closest('form').get(0).reset();
$el.unwrap();

```

### DEMO

See [this jsFiddle](https://jsfiddle.net/gyrocode/yfeo529g/) for code and demonstration.

### LINKS

* [Clearing <input type='file' /> using jQuery](https://stackoverflow.com/a/13351234/3549014)
* [How to reset file input with JavaScript](https://www.gyrocode.com/articles/how-to-reset-file-input-with-javascript/)
With **IE 10** I resolved the problem with :

```
    var file = document.getElementById("file-input");
    file.removeAttribute('value');
    file.parentNode.replaceChild(file.cloneNode(true),file);

```

where :

```
<input accept="image/*" onchange="angular.element(this).scope().uploadFile(this)" id="file-input" type="file"/>

```