XML features, except for saving files in the XML Spreadsheet format, are available only in Microsoft Office Professional Edition 2003 and Microsoft Office Excel 2003.
Do not specify a value for the Destination parameter if you want to import data into an existing mapping.
The following conditions will cause this method to generate run-time errors:
Use the XmlImport method to import an XML data file into the current workbook.
Usage Requirements
XmlImportXml does not work when the ExcelLocale1033Attribute attribute in your project is set to true (the default). If the ExcelLocale1033Attribute attribute is true, you must perform the following steps:
-
You must call the XmlImportXml method of the underlying Microsoft.Office.Interop.Excel.Workbook, instead of the Microsoft.Office.Tools.Excel.Workbook host item.
-
You must use the Unwrap method on all of the following objects before calling XmlImportXml.
-
The underlying Microsoft.Office.Interop.Excel.Workbook.
-
The XmlMap that is passed into the ImportMap parameter.
-
The Range that is passed into the Destination parameter.
Unwrap modifies these objects so that they pass the locale ID of the current thread to the Excel object model, instead of passing locale ID 1033.
The code example in this topic shows how to use XmlImportXml when the ExcelLocale1033Attribute attribute is true. For more information about ExcelLocale1033Attribute and the Unwrap method, see Formatting Data in Excel with Various Regional Settings.
Optional Parameters