我试图了解我在InternetExplorer6和WindowsXP下运行的JavaScript密集型瘦客户端应用程序中看到的间歇性脚本错误。问题的根本原因是以下函数调用返回了一个null值(但它确实成功且没有错误):vardoc=targetWindow.document.open("text/html","_replace");targetWindow是window对象。targetWindow和targetWindow.document都不是null所以我很难理解为什么这个调用会返回null。我对thedocumentation的解读是这个方法永远不应该返回null。此代码多年来