- 2 minutes to read
The ASPxFileManager control supports file upload. The file extensions that can be uploaded are specified by the FileManagerSettings.AllowedFileExtensions property. If this property value is empty, all file extensions are allowed.
When the file manager uploads a file in Advanced mode (the FileManagerSettingsUpload.UseAdvancedUploadMode property is set to
true), the file is sent to the server in small packets (one at a time). The packets are saved into a temporary file until upload is complete. After that, the access rules are applied. If the file upload is denied, the file manager deletes the temporary file and displays an error message. Set the FileManagerUploadAdvancedModeSettings.EnableClientAccessRuleValidation property to
true to allow access rule validation on the client side. In this case, file accessibility is checked before it is uploaded to the server side.
Users can upload files in the following ways:
- Use the upload panel.
- Use the upload button.
- Drop files to the file area (if the FileManagerUploadAdvancedModeSettings.EnableDragAndDrop property is set to
- Click an element whose ID is assigned to the FileManagerSettingsUpload.DialogTriggerID property.
You can restrict uploads to a specific folder determined by the FileManagerSettingsUpload.AllowedFolderPath property if the FileManagerSettingsUpload.AllowedFolder property is set to SpecificOnly. To mark the folders as locked for upload, use special folder icons specified by the FileManagerImages.FolderLocked property. Note that the FileManagerSettingsFolders.ShowLockedFolderIcons property should be set to
Set the FileManagerSettingsUpload.Enabled property to
false to prohibit file upload.