vba MSCOMM32.ocx 使用导致 Not Trusted 错误

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/1403647/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-09-11 10:46:28  来源:igfitidea点击:

MSCOMM32.ocx usage causes Not Trusted Error

vbaexcel-vbamscomm32excel

提问by Manoj

I was using an Excel macro which uses mscomm32.ocx for communicating with the serial port. It was working fine until some one or two month back. Now when we try to run it again it is not working. When I try to load it, it says the "Subject is not trusted for the specified Action". Can any one help me out!?

我正在使用一个 Excel 宏,它使用 mscomm32.ocx 与串行端口进行通信。直到大约一两个月前,它都运行良好。现在,当我们尝试再次运行它时,它不起作用。当我尝试加载它时,它说“指定的操作不信任主题”。谁能帮我吗!?

Thanks...

谢谢...

采纳答案by Manoj

Actually some security upgrades from Microsoft had prevented the older mscomm32.dll from loading. A newer version of the DLL solves the problem Newer version is available as a patch from Microsoft website. But it required VB6 to be installed to work. Do not know how to circumvent that. Thanks...

实际上,微软的一些安全升级阻止了旧的 mscomm32.dll 加载。较新版本的 DLL 解决了该问题 较新版本可作为补丁从 Microsoft 网站获得。但它需要安装 VB6 才能工作。不知道如何规避。谢谢...

回答by Daniel Rikowski

This is most likely the cause of an update of your Excel installation. Newer Office versions have more strict security policies.

这很可能是更新 Excel 安装的原因。较新的 Office 版本具有更严格的安全策略。

This documentdescribes how they can be edited. (Esp. the ActiveX section)

文档描述了如何编辑它们。(尤其是 ActiveX 部分)