/// <summary> /// Handles the UploadedComplete event of the fileLogo control. /// </summary> /// <param name="sender">The source of the event.</param> /// <param name="e">The <see cref="AjaxControlToolkit.AsyncFileUploadEventArgs"/> instance containing the event data.</param> protected void fileLogo_UploadedComplete(object sender, AjaxControlToolkit.AsyncFileUploadEventArgs e) { _fileBytes = ControlUtilities.CompressImage(fileLogo.FileBytes, 70); var base64String = Convert.ToBase64String(_fileBytes, 0, _fileBytes.Length); Image1.ImageUrl = "data:image/jpg;base64," + base64String; }