DocumentHelperAddAttachment Method (TreeNode, String, String, TreeProvider, Int32, Int32, Int32) |
Adds specified attachment to the document. Does not update the document to the database, updates the attachment if currently present.
Namespace: CMS.DocumentEngineAssembly: CMS.DocumentEngine (in CMS.DocumentEngine.dll) Version: 8.2.23
Syntax public static AttachmentInfo AddAttachment(
TreeNode node,
string guidColumnName,
string file,
TreeProvider tree,
int width = -1,
int height = -1,
int maxSideSize = -1
)
Parameters
- node
- Type: CMS.DocumentEngineTreeNode
Document node - guidColumnName
- Type: SystemString
Column containing the Attachment GUID - file
- Type: SystemString
Attachment file path - tree
- Type: CMS.DocumentEngineTreeProvider
TreeProvider to use - width (Optional)
- Type: SystemInt32
New width of the image attachment - height (Optional)
- Type: SystemInt32
New height of the image attachment - maxSideSize (Optional)
- Type: SystemInt32
Maximum side size of the image attachment
Return Value
Type:
AttachmentInfoSee Also