XPath.Clear method (Excel)
Clears all XPath schema information for the mapped range.
Syntax
expression.Clear
expression A variable that represents an XPath object.
Remarks
Clear affects the entire range mapped to the XPath object.
This method does not clear the data from the cells mapped to the specified XPath. Use the Clear method of the Range object to clear the data from the cells.
If the specified XPath is mapped in an XML list, the schema mapping is removed, but the list is not deleted from the worksheet.
If the mapped range is a single-cell, the single-cell is removed and the data remains.
This method produces an error if any of the following conditions are true:
The range spans multiple columns in the grid.
Part of the range spans already mapped cells and the rest spans unmapped cells.
Part of the range spans one mapping, and another part of the range spans a different mapping or different XPath from the same mapping.
Support and feedback
Have questions or feedback about Office VBA or this documentation? Please see Office VBA support and feedback for guidance about the ways you can receive support and provide feedback.