error domexception: failed to set the ‘value’ property on ‘htmlinputelement’: this input element accepts a filename, which may only be programmatically set to the empty string. failed to set the ‘value’ property on ‘htmlinputelement’: this input element accepts a filename, which may only be programmatically set to the empty string.

The solution for “error domexception: failed to set the ‘value’ property on ‘htmlinputelement’: this input element accepts a filename, which may only be programmatically set to the empty string. failed to set the ‘value’ property on ‘htmlinputelement’: this input element accepts a filename, which may only be programmatically set to the empty string.” can be found here. The following code will assist you in solving the problem.

//just remove the formControlName
1) Remove the formControlName

If it doesn’t work
Refer to this stackoverflow answer
https://stackoverflow.com/questions/41889384/angular2-validation-for-input-type-file-wont-trigger-when-changing-the-fi/41938495#41938495

Thank you for using DeclareCode; We hope you were able to resolve the issue.

More questions on [categories-list]

0
inline scripts encapsulated in