次の方法で共有


loadXML Method (Windows Embedded CE 6.0)

1/6/2010

Loads an XML document using the supplied string.

Script Syntax

            boolValue = oXMLDOMDocument.loadXML(bstrXML);

Remarks

Ee502729.collapse(en-US,WinEmbedded.60).gifScript Parameters

  • bstrXML
    String containing the XML string to load into this XML document object. This string can contain an entire XML document or a well-formed fragment.

Ee502729.collapse(en-US,WinEmbedded.60).gifScript Return Value

Boolean. Returns True if the XML load succeeded. Returns False and sets the documentElement property of the DOMDocument to Null if the XML load failed.

Ee502729.collapse(en-US,WinEmbedded.60).gifC/C++ Syntax

HRESULT loadXML(
  BSTR bstrXML,
  VARIANT_BOOL* isSuccessful
);

Remarks

Ee502729.collapse(en-US,WinEmbedded.60).gifC/C++ Parameters

  • bstrXML
    [in] XML string to load into this XML document object. This string can contain an entire XML document or a well-formed fragment.
  • isSuccessful
    [out, retval] True if the XML load succeeded. This method returns False and sets the documentElement property of the DOMDocument object to Null if the XML load failed.

Ee502729.collapse(en-US,WinEmbedded.60).gifC/C++ Return Values

  • S_OK
    Value returned if successful.
  • S_FALSE
    Value returned if the load fails.
  • E_INVALIDARG
    Value returned if isSuccessful is Null.

Ee502729.collapse(en-US,WinEmbedded.60).gifRequirements

Header msxml2.h, msxml2.idl
Windows Embedded CE Windows CE .NET 4.0 and later

General Remarks

Calling the load Method or loadXML on an existing document immediately discards the content of the document. The loadXML will work only with UTF-16 or UCS-2 encodings.

This member is an extension of the World Wide Web Consortium (W3C) Document Object Model (DOM).

This method applies to the following interface:

DOMDocument.

Requirements

Header msxml2.h, msxml2.idl
Windows Embedded CE Windows CE .NET 4.0 and later

See Also

Reference

XML DOM Methods

Concepts

documentElement Property

Other Resources