_Workbook.SaveAsXMLData Method

Exports the data that has been mapped to the specified XML schema map to an XML data file.

Namespace:  Microsoft.Office.Interop.Excel
Assembly:  Microsoft.Office.Interop.Excel (in Microsoft.Office.Interop.Excel.dll)

Syntax

'Declaration
Sub SaveAsXMLData ( _
    Filename As String, _
    Map As XmlMap _
)
'Usage
Dim instance As _Workbook
Dim Filename As String
Dim Map As XmlMap

instance.SaveAsXMLData(Filename, Map)
void SaveAsXMLData(
    string Filename,
    XmlMap Map
)

Parameters

  • Filename
    Type: System.String

    Required String. A string that indicates the name of the file to be saved. You can include a full path; if you don't, Microsoft Excel saves the file in the current folder.

Remarks

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.

This method will result in a run-time error if Excel cannot export data with the specified schema map. To check whether Excel can use the specified schema map to export data, use the IsExportable property.

See Also

Reference

_Workbook Interface

_Workbook Members

Microsoft.Office.Interop.Excel Namespace