MSXML: Difference between revisions

Content deleted Content added
Removing link(s) to "ProgID": Removing links to deleted page ProgID.
 
(178 intermediate revisions by more than 100 users not shown)
Line 1:
{{Short description|Windows-native application building services}}
'''Microsoft XML Core Services''' ('''MSXML''') is a set of services that allow applications written in [[JScript]], [[VBScript]], and Microsoft development tools to build Windows-native XML-based applications. It supports XML 1.0, [[Document Object Model|DOM]], [[SAX]], an XSLT 1.0 processor, XML schema support including [[XML Schema|XSD]] and XDR, as well as other XML-related technologies.
{{primary sources|date=September 2018}}
'''Microsoft XML Core Services''' ('''MSXML''') is aare set of services that allow applications written in [[JScript]], [[VBScript]], and Microsoft development tools to build Windows-native [[XML]]-based applications. It supports XML 1.0, [[Document Object Model|DOM]], [[Simple API for XML|SAX]], an [[XSL Transformations|XSLT]] 1.0 processor, [[XML schema]] support including [[XML Schema|XSD]] and [[XDR Schema|XDR]], as well as other XML-related technologies.
 
==VersionsOverview ==
All MSXML products are similar in that they are exposed programmatically as [[OLE Automation]] (a subset of [[Component Object Model|COM]] (COM) objectscomponents. YouDevelopers can program against MSXML objectscomponents from [[C (programming language)|C]], [[C++]] or from scripts[[Active Scripting]] languages such as JScript and VBScript. Managed .NET Interop with MSXML COM components is not supported ornor recommended.<ref>{{cite web | url = https://support.microsoft.com/en-us/kb/815112 | title = The use of MSXML is not supported in .NET applications | publisher = [[Microsoft]] | access-date = 2010-03-18}}</ref>
MSXML is a collection of distinct products, released and supported by Microsoft. These products can be enumerated as
 
As with all COM components, you programmatically instantiate an MSXML object is programmatically instantiated by CLSID or ProgID. Each version of MSXML exposes its own set of CLSIDsCLSID's and ProgIDs. For example, to create an MSXML 6.0 DOMDocument object, which exposes the [<code>IXmlDomDocument</code>,<ref>{{cite web | url = http://msdn2.microsoft.com/en-us/library/ms756987.aspx IXmlDomDocument| title = IXMLDOMDocument/DOMDocument | publisher = [[MSDN]] | access-date = 2008-05-28}}</ref> <code>IXmlDomDocument2</code>,<ref>{{cite web | url = [http://msdn2.microsoft.com/en-us/library/ms761358.aspx IXmlDomDocument2| title = IXMLDOMDocument2 | access-date = 2008-05-28 | publisher = [[MSDN],]}}</ref> and [<code>IXmlDomDocument3</code><ref>{{cite web | url = http://msdn2.microsoft.com/en-us/library/ms763789.aspx IXmlDomDocument3| title = IXMLDOMDocument3 | access-date = 2008-05-28 | publisher = [[MSDN]]}}</ref> COM interfaces, you use the ProgID "MSXML2.DOMDocument60"DOMDocument.6.0" must be used.
* '''MSXML 6.0''' MSXML6 is the latest MSXML product from Microsoft, and (along with MSXML3) is shipped with [[SQL Server 2005]] and [[Microsoft Windows]] operating system.
* '''MSXML 5.0''' MSXML5 is a binary developed specifically for [[Microsoft Office]].
* '''MSXML 4.0''' MSXML4 was shipped as a separate, downloadable SDK targeted at Independent Software Vendors and third parties.
* '''MSXML 3.0''' MSXML3 is a current MSXML product, represented by msxml3.dll, and is found on Microsoft Windows operating systems.
* '''MSXML 2.6''' This is an early version of MSXML, and is represented by msxml2.dll. This product is no longer supported by Microsoft, and the CLSIDs and ProgIDs it exposes have been subsumed by MSXML 3.0.
* '''MSXML 2.5''' This is an early version of MSXML, and is represented by msxml.dll. This product is no longer supported by Microsoft, and the CLSIDs and ProgIDs it exposes have been subsumed by MSXML 3.0.
 
MSXML also supports version-independent ProgIDs. Version-independent ProgIDs do not have a version number associated with them. For example, "Microsoft.XMLHTTP". These ProgIDs were first introduced in MSXML 1.0, however are currently mapped to MSXML 3.0 objects and the msxml3.dll.
For complete MSXML version information, see the [http://support.microsoft.com/kb/269238 MSXML Version List] at Microsoft.
 
Different versions of MSXML support slightly different sets of functionality. For example, while MSXML 3.0 supports only XDR schemas, it does not support XSD schemas. MSXML 4.0, MSXML 5.0, and MSXML 6.0 support XSD schemas. However, MSXML 6.0 does not support XDR schemas. Support for XML Digital Signatures is provided only by MSXML 5.0. For new XML-related software development, Microsoft recommends<ref>{{cite web | url = http://blogs.msdn.com/xmlteam/archive/2006/10/23/using-the-right-version-of-msxml-in-internet-explorer.aspx | title = Using MSXML in the browser | access-date = 2008-05-28}}</ref> using MSXML 6.0 or its lightweight cousin, ''XmlLite'', for [[native code]]-only projects.<ref>{{cite web | url = http://msdn.microsoft.com/en-us/library/ms752872.aspx | title = XmlLite Programmers' Guide and API Reference | publisher = [[MSDN]] | access-date = 2008-05-28}}</ref>
== Developing software with MSXML ==
For new XML-related software development in C++, use MSXML 6.0 or [http://msdn2.microsoft.com/en-us/library/ms752872.aspx XmlLite]. For guidance on which version of MSXML to use in the browser, refer to the Xml Core Team Blog post,
[http://blogs.msdn.com/xmlteam/archive/2006/10/23/using-the-right-version-of-msxml-in-internet-explorer.aspx Using MSXML in the Browser] at MSDN.
 
== Versions ==
Different versions of MSXML support slightly different sets of functionality. While a complete list of differences is beyond the scope of this article, some examples are provided here.
'''MSXML''' is a collection of distinct products, released and supported by Microsoft. The Theseproduct productsversions can be enumerated as follows:<ref>[http://support.microsoft.com/kb/269238 MSXML Version List] at Microsoft.</ref>
* MSXML 3.0 supports only XDR schemas, it does not support XSD schemas. MSXML 4.0, MSXML 5.0, and MSXML 6.0 support XSD schemas. Finally, MSXML 6.0 does not support XDR schemas.
* MSXML 5.0 contains an implementation of XML Digital Signatures.
 
=== Current ===
All MSXML products are similar in that they are exposed programmatically as [[Component Object Model]] (COM) objects. You can program against MSXML objects from C++ or from scripts languages such as JScript and VBScript. Managed .NET Interop with MSXML COM components is not supported or recommended.
* '''MSXML 6.0''' MSXML6 is the latest MSXML product from Microsoft, and (along with MSXML3) is shipped with [[Microsoft SQL Server 2005]], [[Microsoft Visual Studio|Visual Studio 2005]], [[.NET Framework 3.0]], as well as [[Windows XP Service Pack 3]], [[Windows Vista]] and every subsequent versions of Windows up to [[Windows 11]]. It also has support for native [[64-bit]] environments. It is an upgrade but not replacement for versions 3 and 4 as they still provide legacy features not supported in version 6. Version 6, 4, and 3 may all be installed and running concurrently. MSXML 6 is not supported on [[Windows 9x]]. Windows XP SP3 includes MSXML 6.0 SP2.
* '''MSXML 3.0''' MSXML3 is a current MSXML product, represented by msxml3.dll. MSXML 3.0 SP2 first shipped with [[Windows XP]], [[Internet Explorer]] 6.0 and [[Microsoft Data Access Components|MDAC]] 2.7. Windows XP SP2 includes MSXML 3.0 SP5 as part of MDAC 2.81. Windows 2000 SP4 also ships with MSXML 3.0. By default, Internet Explorer version [[Internet Explorer 6|6.0]], [[Internet Explorer 7.0|7.0]] and [[Internet Explorer 8|8.0]] use MSXML 3 to parse XML documents loaded in a window. MSXML 3.0 SP7 is the last supported version for [[Windows 95]]. Windows XP SP3 includes MSXML 3.0 SP9. [[Windows Vista]] also includes MSXML 3.0 (SP10).
 
=== Obsolete ===
As with all COM components, you programmatically instantiate an MSXML object by CLSID or ProgID. Each version of MSXML exposes its own set of CLSIDs and ProgIDs. For example, to create an MSXML 6.0 DOMDocument object, which exposes the [http://msdn2.microsoft.com/en-us/library/ms756987.aspx IXmlDomDocument], [http://msdn2.microsoft.com/en-us/library/ms761358.aspx IXmlDomDocument2], and [http://msdn2.microsoft.com/en-us/library/ms763789.aspx IXmlDomDocument3] COM interfaces, you use the ProgID "MSXML2.DOMDocument60".
* '''MSXML 5.0''' MSXML5 was a binary developed specifically for [[Microsoft Office]]. It originally shipped with Office 2003 and also ships with [[Office 2007]]. Microsoft has not released documentation for this version because Microsoft considers MSXML 5 an internal/integrated component of Office 2003. MSXML 5 is not included in [[Microsoft Office 2010|Office 2010]].<ref>[https://technet.microsoft.com/en-us/library/cc178954%28office.14%29.aspx#BKMK_WhatsRemoved Office 2010: What's removed: Office 2010 Resource Kit documentation on TechNet]</ref>
* '''MSXML 4.0''' MSXML4 was shipped as an independent, downloadable SDK targeted at [[independent software vendor]]s and third parties. It is an upgrade for, but not a replacement to MSXML3 as version 3 still provides legacy features. There is no 64-bit version offered, although the 32-bit version was supported for 32-bit processes on 64-bit operating systems. Versions 4 and 3 may be run concurrently. MSXML 4.0 SP3 is the most recent version released in March 2009, SP2 support expired in April 2010,<ref name="MSXML4SP3">{{Citation |title=MSXML 4.0 SP3 Release Notes |publisher=[[Microsoft]] |date=2009-09-29 |url=http://download.microsoft.com/download/A/2/D/A2D8587D-0027-4217-9DAD-38AFDB0A177E/MSXML4%20SP3%20RTM%20Release%20Note.htm |access-date=2011-01-21 |archive-date=2020-08-06 |archive-url=https://web.archive.org/web/20200806185226/https://download.microsoft.com/download/A/2/D/A2D8587D-0027-4217-9DAD-38AFDB0A177E/MSXML4%20SP3%20RTM%20Release%20Note.htm |url-status=dead }}</ref> and MSXML 4.0 SP3 expired in April 2014.<ref name="MSXML4SP3SupportLifeCycle">{{Citation |title=MSXML Roadmap |publisher=[[Microsoft]] |date=2013-03-15 |url=https://msdn.microsoft.com/en-us/library/jj152146(v=vs.85).aspx|access-date=2015-07-11}}</ref>
* '''MSXML 2.56''' This is an early version of MSXML, and is represented by msxmlmsxml2.dll. This product is no longer supported by Microsoft, and the CLSIDs and ProgIDs it exposes have been subsumed by MSXML 3.0. MSXML 2.6 shipped with [[Microsoft SQL Server]] 2000 and MDAC 2.6. The last version for all platforms was released as [http://support.microsoft.com/kb/887606 KB887606].
* '''MSXML 2.65''' This is an early version of MSXML, and is represented by msxml2msxml.dll. This productversion is also no longer supported by Microsoft, and the CLSIDs and ProgIDs it exposes have been subsumed by MSXML 3.0. MSXML 2.5 shipped with [[Windows 2000]] as part of [[Internet Explorer]] 5.01 and [[Microsoft Data Access Components|MDAC]] 2.5.
* '''MSXML 2.0a''' This version shipped with [[Internet Explorer 5.0]]. No longer supported.
* '''MSXML 1.0''' This version shipped with [[Internet Explorer 4|Internet Explorer 4.0]]. No longer supported.
 
==See also==
For example to use XML in VB.net, after adding the "Microsoft XML, v6.0" reference to you project you could use "Dim doc As MSXML2.DOMDocument60".
*[[Ajax (programming)]]
 
== References ==
MSXML also supports version-independent ProgIDs. Version-independent ProgIDs do not have a version number associated with them. For example "Microsoft.XMLHTTP". These ProgIDs were first introduced in MSXML 1.0, however are currently mapped to MSXML 3.0 objects and the msxml3.dll.
{{reflist}}
 
== External links ==
*[{{Official website|http://msdn.microsoft.com/library/en-us/xmlsdklibrary/html/b24aafc2-bf1b-4702-bf1c-b7ae3597eb0cms763742.asp MSXML 6.0 SDK] at MSDNaspx}}
*[http://blogs.msdn.com/xmlteam/ MSXMLMicrosoft teamXML blogTeam's WebLog]
**[http://blogs.msdn.com/xmlteam/archive/2006/10/23/using-the-right-version-of-msxml-in-internet-explorer.aspx Using the right version of MSXML in Internet Explorer]
* [http://msdn.microsoft.com/en-us/data/bb190600.aspx Microsoft: Data Developer Center: Learn: MSXML]
*[http://support.microsoft.com/kb/269238 Microsoft: Support: List of Microsoft XML Parser (MSXML) versions]
*[http://www.microsoft.com/download/en/search.aspx?q=MSXML%206.0 Microsoft: Download Center: search results: "MSXML 6.0"]
*[http://www.microsoft.com/download/en/search.aspx?q=MSXML%204.0 Microsoft: Download Center: search results: "MSXML 4.0"]
*[http://www.microsoft.com/download/en/search.aspx?q=MSXML%203.0 Microsoft: Download Center: search results: "MSXML 3.0"]
 
[[Category:{{Microsoft APIs]]}}
{{Internet Explorer}}
[[Category:Microsoft Windows]]
[[Category:XML parsers]]
 
[[Category:Internet Explorer]]
[[de:MSXML]]
[[Category:Microsoft application programming interfaces]]
[[fr:MSXML]]
[[Category:MicrosoftXML Windowsparsers]]
[[Category:XMLXSLT parsersprocessors]]
[[Category:Obsolete technologies]]