问题描述
我有与附件创建一个电子邮件消息的遗留应用程序。在code使用MAPI接口来创建消息。这code曾很长一段时间。
I've got a legacy application that creates an email message with an attachment. The code uses the MAPI interface to create the message. This code has worked for quite some time.
在应用程序运行在Windows 7 64位计算机上,调用MAPILogon失败,一般错误code。
When the application is run on a Windows 7 64 bit machine, the call to MAPILogon fails with a generic error code.
是否与MAPI和Win7 64不兼容?或者是有一些我不知道的COM问题?
Is there an incompatibility with MAPI and Win7 64? Or is there some COM issue that I am not aware of?
推荐答案
它看起来像这个问题取决于你使用的是哪个API调用。
It looks like the problem depends on which API calls you are using.
呼叫至MAPISendMail则应该不会有问题。
Calls to MAPISendMail should work without a problem.
对于所有其他MAPI方法和函数调用在MAPI应用程序中,MAPI应用程序的位数(32或64)工作,必须在相同的计算机上MAPI子系统的位数,该应用程序是针对运行上。
For all other MAPI method and function calls to work in a MAPI application, the bitness (32 or 64) of the MAPI application must be the same as the bitness of the MAPI subsystem on the computer that the application is targeted to run on.
在一般情况下,32位MAPI应用程序,而第一个被重建为64位应用程序。在64位平台(64位Outlook在64位Windows)不能运行。
In general, a 32-bit MAPI application must not run on a 64-bit platform (64-bit Outlook on 64-bit Windows) without first being rebuilt as a 64-bit application.
有关更详细的explination,请参阅构建MAPI应用程序上的MSDN页面32位和64位平台
For a more detailed explination, see the MSDN page on Building MAPI Applications on 32-Bit and 64-Bit Platforms
这篇关于MAPI的Windows 7 64位的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!