CVIXMLCopyElement
- Updated2023-02-21
- 1 minute(s) read
CVIXMLStatus CVIXMLCopyElement (CVIXMLElement element, int copyChildren, CVIXMLElement parentElement, int index, CVIXMLElement *copiedElement);
Purpose
Creates a copy of an element at the specified position. The copyChildren parameter specifies whether or not to copy the children of the element.
Parameters
| Input | ||
| Name | Type | Description |
| element | CVIXMLElement | The element handle must be a valid CVIXMLElement. |
| copyChildren | int | Specify a nonzero value or select Yes in the function panel to copy the child elements. Specify 0 or select No in the function panel to prevent copying of the child elements. |
| parentElement | CVIXMLElement | The element handle must be a valid CVIXMLElement. |
| index | int | The zero-based index at which the element will be inserted under the parent element. Pass –1 to append the element to the end. The index refers to the position of XML elements and does not include other XML entities. |
| Output | ||
| Name | Type | Description |
| copiedElement | CVIXMLElement | On output, contains the handle to the element object created in this function. This handle must be discarded using the CVIXMLDiscardElement function. |
Return Value
| Name | Type | Description | ||||
| status | CVIXMLStatus | Indicates whether the function was successful. A zero indicates success. You can call CVIXMLGetErrorString to obtain textual descriptions of error codes. Among the more commonly encountered errors are:
|
Additional Information
Library: CVIXML
Include file: toolbox\cvixml.h
LabWindows/CVI compatibility: LabWindows/CVI 7.0 and later