This post contains attachments v20010605222658.zip 
Summary
Here is some script that can be used to determine what version of the XML Parser is installed on your computer and whether it is in Replace mode or Side-by-side.
To use this function, create an XmlVersionSniffer object, and view the properties version, replace, and versions. Like this:
<script language=javascript> var xmlsniffer = new XmlVersionSniffer(); document.writeln(Highest Version: + xmlsniffer.version); document.writeln(Replace Mode: + xmlsniffer.replace); document.writeln(All Versions:); for (var version in xmlsniffer.versions) { document.writeln(xmlsniffer.versions[\ + version + \] == + xmlsniffer.versions[version]); } document.writeln(<hr>Log:<br> + xmlsniffer.log); </script>
Read the comments in the code to see how it works.
To verify the code, do the following at the command line:
xmlinst -u regsvr32 -u msxml4.dll (xmlinst does not work on version 4)At this point, there is no parser defined, so you should get
Highest Version: unknown Replace Mode: false
Now type the following to install the original parser in IE5.
regsvr32 msxml.dll
You should now get:
Highest Version: 2.5 Replace Mode: false All Versions: xmlsniffer.versions[2.5] == true
Now type the following:
regsvr32 msxml2.dll
You should now get:
Highest Version: 2.6 Replace Mode: false All Versions: xmlsniffer.versions[2.5] == true xmlsniffer.versions[2.6] == true
Now type the following:
regsvr32 msxml3.dll
You should now get:
Highest Version: 3.0 Replace Mode: false All Versions: xmlsniffer.versions[2.5] == true xmlsniffer.versions[2.6] == true xmlsniffer.versions[3.0] == true xmlsniffer.versions[3.0sp1] == true
Note: 3.0sp1 is true only if Service Pack 1 has been installed.
Now type the following:
regsvr32 msxml4.dll
You should now get:
Highest Version: 4.0 Replace Mode: false All Versions: xmlsniffer.versions[2.5] == true xmlsniffer.versions[2.6] == true xmlsniffer.versions[3.0] == true xmlsniffer.versions[3.0sp1] == true xmlsniffer.versions[4.0] == true
So up to this point, we have been in side-by-side mode. So lets run xmlinst. First we'll reset everything, and get to version 3
xmlinst -u regsvr32 -u msxml4.dll regsvr32 msxml.dll regsvr32 msxml2.dll regsvr32 msxml3.dll xmlinst
Now we should get:
Highest Version: 3.0 Replace Mode: true ...
If you had version 4 installed, don't forget to do this:
regsvr32 msxml4.dll
Ok, well that's all.
Any feedback would be appreciated.
-- Michael J. Carter Sr. Software Engineer
__ s t a r w i r e ________________________________ Focusing the power of the Internet for networked communities. t: 510.723.1020 x270 f: 510.723.1021 mcarter@starwire.com http://www.starwire.com
|