XMLLocation Property

Microsoft Office Web Components Object Model

Show All

XMLLocation Property

       

Returns or sets a DscXMLLocationEnum constant that specifies whether the XML data is to be loaded or saved from an XML data file or an XML data island inside of the current data access page. Read/write.

DscXMLLocationEnum can be one of these DscXMLLocationEnum constants.
dscXMLDataFile The XML data is stored in a separate file.
dscXMLEmbedded The XML data is stored in an XML data island located in the current data access page.

expression.XMLLocation

expression   Required. An expression that returns a DataSourceControl object.

Example

This example exports the current data in the data source control named MSODSC to an XML data file.

Sub ExportData()

   Dim dscConstants

   Set dscConstants = MSODSC.Constants

   ' Set the location of the XML data to a data file.
   MSODSC.XMLLocation = dscConstants.dscXMLDataFile

   ' Set the specific target to export to.
   MSODSC.XMLDataTarget = "Q1 Sales Analysis.xml"

   ' Export the current data.
   MSODSC.ExportXML

End Sub