New to Telerik UI for ASP.NET AJAX? Download free 30-day trial

OnClientFileUploaded

The OnClientFileUploaded client-side event occurs after a file has been uploaded

The event handler receives two parameters:

  1. The instance of the RadAsyncUpload control firing the event.

  2. An eventArgs parameter containing the following methods:

  • get_fileInfo returns fileInfo object containing information regarding the uploaded file. Essentially, this is the UploadedFileInfo object serialized from the HttpHandler

  • get_fileName returns the name of the file selected

  • get_row returns the upload row for which the event was fired.

<telerik:RadAsyncUpload RenderMode="Lightweight" runat="server" ID="RadAsyncUpload1" OnClientFileUploaded="OnClientFileUploaded"></telerik:RadAsyncUpload>
function OnClientFileUploaded(sender, args) {
    var contentType = args.get_fileInfo().ContentType;
    var filename = args.get_fileName();
    var currentRowElement = args.get_row();
    alert(contentType);
}
In this article