Fires before a file is uploaded to the Document Selector and allows you to cancel the action.
public event FileManagerFileUploadEventHandler DocumentSelectorFileUploading
Public Event DocumentSelectorFileUploading As FileManagerFileUploadEventHandler
The DocumentSelectorFileUploading event handler receives an argument of the FileManagerFileUploadEventArgs type.
The following properties provide information specific to this event.
Prior to each time a file is uploaded to the Document Selector, the DocumentSelectorFileUploading event occurs, allowing you to cancel the file upload. The event parameter's FileManagerFileUploadEventArgs.File property identifies the file that is being processed. The FileManagerFileUploadEventArgs.InputStream and FileManagerFileUploadEventArgs.OutputStream properties allow you to modify a file, before sending it to the server side. The FileManagerFileUploadEventArgs.FileName property allows you specify a custom name for the file.
To cancel the upload operation, set the FileManagerActionEventArgsBase.Cancel property to true. To show a message explaining the reason for the upload cancellation, specify the FileManagerActionEventArgsBase.ErrorText property.