VB6 程序会挂起(减慢)Windows 7 64 位版本,但不会在 32 位版本中挂起。有什么解决办法吗?
我们有一个用 VB6 编写的程序,可以随时在双核 Windows7 32 位上运行良好。现在我们正在Windows7 64位(双核)上进行尝试,令我们惊讶的是它运行得不太好:在长进程、长循环中,系统变得饱和(处理器使用50%时挂起)并且无法更改为另一个程序(例如:ALT+TAB 不起作用或运行速度非常慢),就像 5-10 年前,当时我们的计算机只有一个处理器或内核。有什么想法吗?有什么限制吗? 64 位 SO 和 VB6 运行时有瓶颈吗?
目前是老式且不优雅的解决方案:我可以通过禁用和启用所有控件的 Doevents (我们已经尝试过,并且有效)来解决此问题,但是它充满了启用/禁用的控件,很难管理它并返回正确的状态
提前致谢。
更新信息:如果我们运行 2 个基于 32 位模式的应用程序(它在任务管理器中注释为 *32),当其中一个应用程序挂起 Windows7 时,ALT+TAB 在 32 位应用程序和图形用户界面工作正常。但如果我们更改为使用 64 位的应用程序,GUI 就不会响应。
We have a program coded in VB6 running well on Windows7 32-bit with a Dual core, at any time. Now we are trying on Windows7 64-bit (dual core), and our surprise is that it's not working so fine: In long process, long loops, the system becomes saturated (hangs with 50% processor use) and it's impossible to change to another program (for example: ALT+TAB doesn't work or works very slowly), like 5-10 years ago, when our computers had only one processor or core. Any idea? Any limitation? Any bottleneck with 64-bit SO and VB6 runtime?
Old-fashion and not elegant solution at this time: I can fix this with Doevents (We've tried it, and it works) disabling and enabling all the controls, but it's full of enabled/disabled controls and it's hard to manage this and return the correct state
Thanks in advance.
Update Info: If we are running 2 applications based on 32 bits mode (it notes in taskmanager like *32), when one of them hangs the Windows7, the ALT+TAB works fine between 32 bits applications and GUI works fine. But if we change to an application using 64 bits, the GUI doesn't reponse.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
好的,谢谢您的评论。最后,三天后,我们发现了问题!
在代码中进行了大量具有不同路径的建筑物之后,我们找到了一种方法,可以使用以下方法在 Farpoint Spread v7 上启用工具提示(textTip/textTipDelay):
该控件包含在一个永远不会卸载的表单上,只是我们隐藏了它。如果我们卸载表单或者注释这两行代码,问题就会消失。
也许马特有正确的解决方案,启动工具提示事件的控件中的某些计时器会挂起或挂钩系统中的某些内容。
再次感谢。
OK, thank you for your comments. At the end, after 3 days, we found the problem!
After a lot of buildings with differents paths in the code, we found a method that enables the tooltips on a Farpoint Spread v7 with the methods (textTip/textTipDelay):
This control is contained on a Form that never unload, only we hide it. If we unload the form or we comment these two lines of code, the problem disappears.
Maybe Matt had the right path to the solution, some Timer in the control that launch the tooltip event hangs or hooks something in the system.
Thx again.