将 64 位 DLL 链接到 Visual Basic 6

发布于 2024-08-18 15:58:47 字数 322 浏览 2 评论 0原文

我正在更新用 C 编写的现有 DLL 项目。出于多种原因,需要 32 位和 64 位版本。

使用这些 DLL 的应用程序是用 Visual Basic 6 编写的,项目中的类需要它。此类包含一个充满 DLL 的公共声明函数的模块;该类是模块中函数的包装器。

Visual Basic 6 项目本身没有任何引用。到目前为止,我已经完成了 32 位版本的编码,并对它感到满意。

考虑到在用 Visual Basic 6 编写的 32 位应用程序中将从 32 位 DLL 调用 64 位 DLL,将模块中的文件名更改为指向 64 位 DLL 是否存在任何问题?

I'm updating an existing DLL project written in C. For multiple reasons, both 32bit and 64bit versions of this are required.

The application using these DLLs is written in Visual Basic 6 and is needed by a class within the project. This class contains a module full of Public Declare Functions to the DLL; the class is a wrapper to the functions in the module.

There are no references in the Visual Basic 6 project itself. So far I've finished coding the 32bit version and am happy with it.

Are there any issues with changing the file name in the module to point at the 64bit DLL, given the 64bit DLL will be called from a 32bit DLL, within a 32bit application, written in Visual Basic 6?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(3

夏有森光若流苏 2024-08-25 15:58:47

您无法从 32 位调用 64 位代码。执行此操作的唯一方法是在 64 位进程中运行 64 位代码,并使用某种进程间通信来与它们通信。

You can't call 64 bit code from 32 bit. The only way to do this run the 64 bit code in a 64 bit process and use some sort of inter-process communication to talk to them.

岁吢 2024-08-25 15:58:47

Raymond“旧新事物”有一篇好文章 这解释了为什么无法从 32 位转换为 64 位。

Raymond "The Old New Thing" has a nice article that explains why it is not possible to thunk from 32-bit to 64-bit.

唯憾梦倾城 2024-08-25 15:58:47

恕我直言,VB6 于 1998 年问世,当时尚不完全清楚计算是否会从 16 位迁移到 32 位,更不用说 64 位处理了。除非你想出某种 64 位 <-> 16/32 位互通层,这不是直接可能的。至少不是通过VB6的方式

With all due respect toward VB6, VB6 came out in 1998, the era when it was not entirely clear if computing will migrate from 16-bit to 32-bit, let alone 64-bit processing. Unless you come up with some sort of a 64-bit <-> 16/32-bit intercommunication layer, this isn't directly possible. At least not through the means of VB6

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文