Class Uploader
Inheritance
System.Object
Uploader
Assembly: Syncfusion.EJ2.dll
public class Uploader : EJTagHelper
Constructors
Declaration
Properties
Triggers after all the selected files has processed to upload successfully or failed to server.
Declaration
public string ActionComplete { get; set; }
Property Value
Type |
Description |
System.String |
|
Specifies the extensions of the file types allowed in the uploader component and pass the extensions
with comma separators. For example,
if you want to upload specific image files, pass allowedExtensions as “.jpg,.png”.
Declaration
public string AllowedExtensions { get; set; }
Property Value
Type |
Description |
System.String |
|
Configures the save and remove URL to perform the upload operations in the server asynchronously.
Declaration
public UploaderAsyncSettings AsyncSettings { get; set; }
Property Value
By default, the uploader component initiates automatic upload when the files are added in upload queue.
If you want to manipulate the files before uploading to server, disable the autoUpload property.
The buttons “upload” and “clear” will be hided from file list when autoUpload property is true.
Declaration
public bool AutoUpload { get; set; }
Property Value
Type |
Description |
System.Boolean |
|
Triggers on remove the uploaded file. The event used to get confirm before remove the file from server.
Declaration
public string BeforeRemove { get; set; }
Property Value
Type |
Description |
System.String |
|
Triggers when the upload process before. This event is used to add additional parameter with upload request.
Declaration
public string BeforeUpload { get; set; }
Property Value
Type |
Description |
System.String |
|
You can customize the default text of “browse, clear, and upload” buttons with plain text or HTML elements.
The buttons’ text can be customized from localization also. If you configured both locale and buttons property,
the uploader component considers the buttons property value.
{% codeBlock src='uploader/buttons/index.md' %}{% endcodeBlock %}
Declaration
public UploaderButtonsProps Buttons { get; set; }
Property Value
Fires if cancel the chunk file uploading.
Declaration
public string Canceling { get; set; }
Property Value
Type |
Description |
System.String |
|
Triggers when changes occur in uploaded file list by selecting or dropping files.
Declaration
public string Change { get; set; }
Property Value
Type |
Description |
System.String |
|
Fires if the chunk file failed to upload.
Declaration
public string ChunkFailure { get; set; }
Property Value
Type |
Description |
System.String |
|
Fires when the chunk file uploaded successfully.
Declaration
public string ChunkSuccess { get; set; }
Property Value
Type |
Description |
System.String |
|
Fires when every chunk upload process gets started. This event is used to add additional parameter with upload request.
Declaration
public string ChunkUploading { get; set; }
Property Value
Type |
Description |
System.String |
|
Declaration
protected override string ClassName { get; }
Property Value
Type |
Description |
System.String |
|
Overrides
Triggers before clearing the items in file list when clicking “clear”.
Declaration
public string Clearing { get; set; }
Property Value
Type |
Description |
System.String |
|
Triggers when the component is created.
Declaration
public string Created { get; set; }
Property Value
Type |
Description |
System.String |
|
Specifies the CSS class name that can be appended with root element of the uploader.
One or more custom CSS classes can be added to a uploader.
Declaration
public string CssClass { get; set; }
Property Value
Type |
Description |
System.String |
|
Specifies a Boolean value that indicates whether the folder of files can be browsed in the uploader component.
Declaration
public bool DirectoryUpload { get; set; }
Property Value
Type |
Description |
System.Boolean |
|
Specifies the drop target to handle the drag-and-drop upload.
By default, the component creates wrapper around file input that will act as drop target.
Declaration
public string DropArea { get; set; }
Property Value
Type |
Description |
System.String |
|
Specifies the drag operation effect to the uploader component. Possible values are Copy , Move, Link and None.
Declaration
public DropEffect DropEffect { get; set; }
Property Value
Specifies Boolean value that indicates whether the component is enabled or disabled.
The uploader component does not allow to interact when this property is disabled.
Declaration
public bool Enabled { get; set; }
Property Value
Type |
Description |
System.Boolean |
|
Enable or disable persisting component's state between page reloads.
Declaration
public bool EnablePersistence { get; set; }
Property Value
Type |
Description |
System.Boolean |
|
Enable or disable rendering component in right to left direction.
Declaration
public bool EnableRtl { get; set; }
Property Value
Type |
Description |
System.Boolean |
|
Triggers when the AJAX request fails on uploading or removing files.
Declaration
public string Failure { get; set; }
Property Value
Type |
Description |
System.String |
|
Triggers before rendering each file item from the file list in a page.
It helps to customize specific file item structure.
Declaration
public string FileListRendering { get; set; }
Property Value
Type |
Description |
System.String |
|
Specifies the list of files that will be preloaded on rendering of uploader component.
The property used to view and remove the uploaded files from server. By default, the files are configured with
uploaded successfully state. The following properties are mandatory to configure the preload files:
Name
Size
Type
Declaration
public List<UploaderUploadedFiles> Files { get; set; }
Property Value
Declaration
public override ModelExpression For { get; set; }
Property Value
Type |
Description |
Microsoft.AspNetCore.Mvc.ViewFeatures.ModelExpression |
|
Overrides
You can add the additional html attributes such as disabled, value etc., to the element.
If you configured both property and equivalent html attribute then the component considers the property value.
{% codeBlock src='uploader/htmlAttributes/index.md' %}{% endcodeBlock %}
Declaration
public object HtmlAttributes { get; set; }
Property Value
Type |
Description |
System.Object |
|
Declaration
protected override bool IsFor { get; }
Property Value
Type |
Description |
System.Boolean |
|
Overrides
Overrides the global culture and localization value for this component. Default global culture is 'en-US'.
Declaration
public string Locale { get; set; }
Property Value
Type |
Description |
System.String |
|
Specifies the maximum allowed file size to be uploaded in bytes.
The property used to make sure that you cannot upload too large files.
Declaration
public double MaxFileSize { get; set; }
Property Value
Type |
Description |
System.Double |
|
Specifies the minimum file size to be uploaded in bytes.
The property used to make sure that you cannot upload empty files and small files.
Declaration
public double MinFileSize { get; set; }
Property Value
Type |
Description |
System.Double |
|
Specifies a Boolean value that indicates whether the multiple files can be browsed or
dropped simultaneously in the uploader component.
Declaration
public bool Multiple { get; set; }
Property Value
Type |
Description |
System.Boolean |
|
Declaration
protected override string NameSpace { get; }
Property Value
Type |
Description |
System.String |
|
Overrides
Fires if pause the chunk file uploading.
Declaration
public string Pausing { get; set; }
Property Value
Type |
Description |
System.String |
|
Triggers when uploading a file to the server using the AJAX request.
Declaration
public string Progress { get; set; }
Property Value
Type |
Description |
System.String |
|
Triggers on removing the uploaded file. The event used to get confirm before removing the file from server.
Declaration
public string Removing { get; set; }
Property Value
Type |
Description |
System.String |
|
DEPRECATED-Triggers before rendering each file item from the file list in a page.
It helps to customize specific file item structure.
Declaration
public string Rendering { get; set; }
Property Value
Type |
Description |
System.String |
|
Fires if resume the paused chunk file upload.
Declaration
public string Resuming { get; set; }
Property Value
Type |
Description |
System.String |
|
Triggers after selecting or dropping the files by adding the files in upload queue.
Declaration
public string Selected { get; set; }
Property Value
Type |
Description |
System.String |
|
By default, the file uploader component is processing the multiple files simultaneously.
If sequentialUpload property is enabled, the file upload component performs the upload one after the other.
Declaration
public bool SequentialUpload { get; set; }
Property Value
Type |
Description |
System.Boolean |
|
Specifies a Boolean value that indicates whether the default file list can be rendered.
The property used to prevent default file list and design own template for file list.
Declaration
public bool ShowFileList { get; set; }
Property Value
Type |
Description |
System.Boolean |
|
Triggers when the AJAX request gets success on uploading files or removing files.
Declaration
public string Success { get; set; }
Property Value
Type |
Description |
System.String |
|
Declaration
protected override string TagName { get; }
Property Value
Type |
Description |
System.String |
|
Overrides
Specifies the HTML string that used to customize the content of each file in the list.
Declaration
public string Template { get; set; }
Property Value
Type |
Description |
System.String |
|
Triggers when the upload process gets started. This event is used to add additional parameter with upload request.
Declaration
public string Uploading { get; set; }
Property Value
Type |
Description |
System.String |
|