MSXML2.ServerXMLHTTP.4.0 来源? [英] MSXML2.ServerXMLHTTP.4.0 Source?

查看:69
本文介绍了MSXML2.ServerXMLHTTP.4.0 来源?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

对象MSXML2.ServerXMLHTTP.4.0"从何而来?哪个安装包?

Where does the object "MSXML2.ServerXMLHTTP.4.0" come from? Which install package?

我正在尝试执行以下操作:

I'm attempting to do the following:

Set oXMLHTTP = CreateObject("MSXML2.ServerXMLHTTP.4.0")

此尝试在我的开发机器上失败(没有返回任何对象),但在我同事的开发机器上成功.显然,他安装了一些我没有安装的东西,反之亦然,但是这个对象、dll 等来自哪里?

This attempt fails on my development machine (no object is returned) but it is successful on my colleague's development machine. Obviously, he has something installed that I don't or vice versa but where does this object, dll, etc come from?

我需要安装什么才能使此调用正常工作?

What would I need to install to get this call to work?

作为记录,将对象更改为其他版本不是一种选择,因为这依赖的代码已针对此特定版本进行了几天的测试.我们不得不回去再次测试......

For the record, changing the object to a different version isn't an option because code that this depends on was tested for several days against this specific version. We'd have to go back and test again...

为了扩展这个问题,我如何知道当前安装的是哪个版本的 MS XML?

To expand on this question, how can I tell which version of MS XML is currently installed?

推荐答案

尝试使用这个功能:-

Function ProgIDInstalled(progID)
    On Error Resume Next
    Dim o : Set o = CreateObject(progID)
    ProgIDInstalled = Err.Number = 0
End Function

If ProgIDInstalled("MSXML2.DOMDocument.3.0") Then
    ' MSXML3 is present   '
End If

If ProgIDInstalled("MSXML2.DOMDocument.4.0") Then
    ' MSXML4 is present   '
End If

If ProgIDInstalled("MSXML2.DOMDocument.5.0") Then
    ' MSXML5 is present   '
End If

If ProgIDInstalled("MSXML2.DOMDocument.6.0") Then
    ' MSXML6 is present   '
End If

令我惊讶的是,即使是现在,仍然有针对 4.0 版本的新开发.Microsoft 现在只修补 3.0 版和 6.0 版 MSXML 核心.

It surprises me that even now there are still new developments being made against the 4.0 version. Microsoft are now only patching version 3.0 and version 6.0 MSXML cores.

我现在知道为时已晚,但实际上您应该使用 3.0,它的优势在于它在当前支持的所有 Windows 平台上无处不在,因此您根本不需要考虑安装它.或者使用 6.0,因为您需要包含 MSXML 的分发,它也可能是 6,因为这是最新的,而且 4 和 5 都没有获得任何安全补丁.

I know its too late now but really you should either be using 3.0 which has the advantage that is it ubiquitous on all Windows platforms currently in support so you don't really need to consider installing it at all. OR be using 6.0 since you need to include a distribution of MSXML it may as well be 6 since that is the latest and neither 4 nor 5 get any security patches.

这篇关于MSXML2.ServerXMLHTTP.4.0 来源?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆