0

作为上一篇关于我的 VBA/Rhinoscript 的后续文章,当我从最初在 Excel 2007 中创建的 Excel 电子表格执行以下 VBA 代码时,我遇到了一个非常奇怪的“灾难性”错误,我现在正在尝试在 Excel 2016 中运行:

Set Rhino = CreateObject("Rhino4.Interface")
If (Err.Number <> 0) Then
    'MsgBox ("Failed to create Rhino4 object")
    Set Rhino = CreateObject("Rhino4.Application")
    If (Err.Number <> 0) Then
        MsgBox "Failed to create Rhino4 object: " & Err.Number
        Exit Sub
    End If
End If

CreateObject检查失败后,Run-time error 8000fff Automation error, Catastrophic failure. 人们模糊地提到在 Excel 版本之间迁移是一个问题,并在工具-> 参考下查看,但我不确定我应该寻找什么。有人知道吗?

谢谢,

马特

4

1 回答 1

0

我可以让您的代码在这里与 Excel 2010 和 Rhino 4.0 SR9 一起工作。

如果您没有运行 Rhino 4.0 SR9,那么我建议您下载并安装此服务版本:

http://www.rhino3d.com/download/rhino/4.0/sr

我的猜测是 Rhino 的 COM 组件没有注册属性(在 Windows 注册表中)。安装最新的服务版本应该可以解决这个问题。

如果这有帮助,现在让我说。

——戴尔

于 2017-02-03T21:01:36.750 回答