Answer the question
In order to leave comments, you need to log in
How to get IFormFile from input[type=file] in Blazor?
I am writing an application on the Blazor Server Side. There is a task to get IFormFile from input.
There is this code:
<input type="file" class="form-control" id="file" @bind-value="file" placeholder="Выберите файл" />
....
...
....
@code {
IFormFile file;
}
System.InvalidOperationException: "The type 'Microsoft.AspNetCore.Http.IFormFile' does not have an associated TypeConverter that supports conversion from a string. Apply 'TypeConverterAttribute' to the type to register a converter."
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question