FileAttachmentsOptions.CustomSaveFiles Event
Occurs when attached files are about to be saved to a hard disk.
Namespace: DevExpress.ExpressApp.FileAttachments.Win
Assembly: DevExpress.ExpressApp.FileAttachment.Win.v24.1.dll
NuGet Package: DevExpress.ExpressApp.FileAttachment.Win
Declaration
Event Data
The CustomSaveFiles event's data class is CustomFileListOperationEventArgs. The following properties provide information specific to this event:
Property | Description |
---|---|
FileDataList | Specifies files about to be saved to a hard disk. |
Handled | Gets or sets a value that indicates whether the event handler has completely handled the event or whether the system should continue its own processing. Inherited from HandledEventArgs. |
Remarks
For more information, refer to the following Module event description: CustomSaveFiles.
The following example demonstrates how to handle this event:
File: MySolution.Win\Startup.cs.
using DevExpress.ExpressApp.ApplicationBuilder;
using DevExpress.ExpressApp.Win.ApplicationBuilder;
// ...
public class ApplicationBuilder : IDesignTimeApplicationFactory {
public static WinApplication BuildApplication(string connectionString) {
var builder = WinApplication.CreateBuilder();
builder.UseApplication<MySolutionWindowsFormsApplication>();
builder.Modules
// ...
.AddFileAttachments(options => {
options.CustomSaveFiles += (s, e) => {
// ...
};
})
// ...
}
// ...
}
See Also