RichEditSettings.SettingsDocumentSelector Property
Provides access to settings that are related to the FileManager used in some built-in File Dialogs.
Namespace: DevExpress.Web.Mvc
Assembly: DevExpress.Web.Mvc5.v24.2.dll
Declaration
Property Value
Type | Description |
---|---|
RichEditDocumentSelectorSettings | An RichEditDocumentSelectorSettings object that contains the Document Selector dialog’s settings. |
Remarks
The example below demonstrates how to prevent users from loading documents in a format other than DOCX:
@Html.DevExpress().RichEdit(settings => {
settings.Name = "RichEdit";
settings.CallbackRouteValues = new { Controller = "Home", Action = "RichEditPartial" };
settings.WorkDirectory = @"~\App_Data\WorkDirectory\";
settings.SettingsDocumentSelector.UploadSettings.Enabled = true;
settings.SettingsDocumentSelector.CommonSettings.AllowedFileExtensions = new String[] {".docx"};
settings.SettingsDocumentSelector.UploadSettings.ValidationSettings.NotAllowedFileExtensionErrorText = "This file extention isn't allowed.";
}).GetHtml()
See Also