0

在我的 VB6 应用程序中,有时在某些客户 PC 中,我们会收到类似错误

Automation error
The remote procedure call failed.

错误来自下面显示的代码

Dim WithEvents Web_popup  As SHDocVw.InternetExplorer 
    Set Web_popup = Nothing
    Set Web_popup = New SHDocVw.InternetExplorer 
    Set ppDisp = Web_popup.Application

也适用于以下代码

Dim iE As New SHDocVw.InternetExplorer iE.Navigate "www.example.com", 4 + 8
iE.Visible = True 

这些错误的原因可能是什么?如何解决?

4

1 回答 1

0

在寻求帮助时,您应该提供更多信息。更重要的是,您应该准确指出导致错误的行。话虽如此,在我看来,您没有检查将 html 下载到资源管理器的就绪状态。在网页未完全下载之前与网页交互会导致此症状。

如果您正在检查就绪状态,我能够产生错误的唯一其他方法是在 Internet Explorer 中打开保护模式。某些网站在保护模式开启时会导致错误。

于 2014-05-10T11:38:25.853 回答