Click or drag to resize
DocumentHelperCopyDocument Method (TreeNode, Int32, Boolean, TreeProvider, Int32, Int32, Boolean, String)

Note: This API is now obsolete.

Copies the node to the specified location.

Namespace: CMS.DocumentEngine
Assembly: CMS.DocumentEngine (in CMS.DocumentEngine.dll) Version: 8.2.23
Syntax
C#
[ObsoleteAttribute("This method is obsolete. Use overload method to pass parent document instance instead of the ID.")]
public static TreeNode CopyDocument(
	TreeNode node,
	int targetParentNodeId,
	bool includeChildNodes = false,
	TreeProvider tree = null,
	int newDocumentsOwner = 0,
	int newDocumentsGroup = 0,
	bool copyPermissions = false,
	string newDocumentName = null
)

Parameters

node
Type: CMS.DocumentEngineTreeNode
Document node to copy
targetParentNodeId
Type: SystemInt32
Target location
includeChildNodes (Optional)
Type: SystemBoolean
Copy also the node child nodes.
tree (Optional)
Type: CMS.DocumentEngineTreeProvider
TreeProvider to use
newDocumentsOwner (Optional)
Type: SystemInt32
Owner of the new documents
newDocumentsGroup (Optional)
Type: SystemInt32
Group of the new documents
copyPermissions (Optional)
Type: SystemBoolean
Indicates whether the document permissions should be copied.
newDocumentName (Optional)
Type: SystemString
New document name

Return Value

Type: TreeNode
See Also