DictionaryXMLTransformsFreeThreaded.GetXMLFromFile Method (PIA)

Use this method to generate an XML Document Object Model (DOM) document from the specified file.

Definition

[Visual Basic .NET]

Imports Microsoft.CommerceServer.Interop
…
Public Function GetXMLFromFile(sFileName As String) As IXMLDOMObject

[C#]

using Microsoft.CommerceServer.Interop;
using MSXMLLib;                        //For IXMLDOMDocument
…
public IXMLDOMDocument GetXMLFromFile(stringsFileName);

Parameters

[Visual Basic .NET]

  • sFileName
    A String that contains the name of the file to convert.

[C#]

  • sFileName
    A string that contains the name of the file to convert.

Return Values

[Visual Basic .NET] If this method completes successfully, it returns an object reference to an XMLDOMDocument object containing the converted file data.

[C#] This method returns an IXMLDOMDocument interface of the XMLDOMDocument object, which will contain the converted file data.

Exceptions

This method may throw one of many mapped exceptions or an exception of type CommerceException.

Remarks

This method does not return an error when the file specified by sFileName is an .exe file, a text file, an invalid XML file, or a nonexistent file. The error type can be found only by viewing the ParseError property of the DOMDocument object. 

[C#] The returned interface is valid only if the method completes successfully.

Requirements

Namespace: Microsoft.CommerceServer.Interop

Platforms: Windows 2000, Windows Server 2003

Assembly: Microsoft.CommerceServer.Runtime.DictionaryXMLTransform.dll

See Also

DictionaryXMLTransformsFreeThreaded class

Copyright © 2005 Microsoft Corporation.
All rights reserved.