Radzen Upload - Error message display

Hi,
I have this upload component and I wonder if there is a way to get back the error message from controller to the upload component?

public async Task Single(IFormFile file)
{
try
{

            await UploadFile(file);
            return StatusCode(200);
        }
        catch (Exception ex)
        {
            return StatusCode(500, ex.Message);
        }
    }
> <h4 class="mb-4">Upload Orders With Excel</h4>
>                 <RadzenUpload Url="upload/single" Progress=@TrackProgress Complete=@CompleteUpload class="w-100" />
>                 <RadzenProgressBar Value=@progress class="mt-4" Visible=@showProgress/>
>                 <RadzenLabel Visible=@showComplete class="mt-4" Text="Upload Complete!"/>

Hi @Developer06,

You can try the Error event of RadzenUpload.

void UploadError(UploadErrorEventArgs args)
{
   var message = args.Message;
}
1 Like

Thank you @korchev , for fast response.