Represents a control that allows users to attach files to the form.
Inherits from
Syntax
public class Attachments : System.Windows.Controls.Grid
Properties
Name | Description |
CurrentTotalAttachmentsSize | Gets current size of all attachments together in bytes. |
DataSource | Gets or sets attachments data in XML format. |
FileSizeExceededMessage | Gets or sets an error message when added file size exceeds size limit. |
Filter | Gets or sets file extension filter. |
IsAddButtonVisible | Gets or sets a flag indicating whether the “Add” button is visible. |
MaxFileLength | Gets or sets maximum size of any one attachment in bytes. |
MaxTotalAttachmentsSize | Gets or sets maximum size of all attachments together in bytes. |
Title | Gets or sets a title text of the control. |
TitleTextWrapping | Gets or sets a flag indicating whether to wrap title text. |
TotalFileSizeExceededMessage | Gets or sets an error message when total file size of all attachments exceeds size limit. |
Methods
Name | Description |
AddAttachment() | Lets users select a file that is then added as an attachment. |
AddAttachment(FileInfo) | Adds a file as an attachment. |
GetAttachments() | Returns information about all attachments. |
RemoveAttachment(Guid) | Removes an attachment by its unique identifier. |
Events
Name | Description |
Added | Occurs when an attachment is added. |
Removed | Occurs when an attachment is removed. |