Skip to main content

DevExpress v24.2 Update — Your Feedback Matters

Our What's New in v24.2 webpage includes product-specific surveys. Your response to our survey questions will help us measure product satisfaction for features released in this major update and help us refine our plans for our next major release.

Take the survey Not interested

DxUpload.FileReloaded Event

Fires when a file is reloaded.

Namespace: DevExpress.Blazor

Assembly: DevExpress.Blazor.v24.2.dll

NuGet Package: DevExpress.Blazor

#Declaration

C#
[Parameter]
public EventCallback<FileReloadedEventArgs> FileReloaded { get; set; }

#Event Data

The FileReloaded event's data class is FileReloadedEventArgs. The following properties provide information specific to this event:

Property Description
NewFileInfo Contains information about the reloaded file.
OldFileInfo Contains information about the file before the reload.

#Remarks

The FileReloaded event occurs after a user reloads a file whose upload was canceled. Users can cancel file upload if the AllowCancel property is set to true.

Razor
<DxUpload Name="myFile" UploadUrl="https://localhost:10000/api/Upload/Upload/" 
          FileReloaded="@OnFileReloaded">
</DxUpload>
<div class="alert alert-info @(MessageVisible? " visible" : " invisible")">@MyMessage</div>

@code {
    bool MessageVisible { get; set; } = false;
    string MyMessage { get; set; } = "";

    void OnFileReloaded(FileReloadedEventArgs args) {
        MyMessage = "The " + args.NewFileInfo.Name + " file was reloaded.";
        MessageVisible = true;
        InvokeAsync(StateHasChanged);
    }
}

Upload File Reloaded

See Also