问题描述
您好,
我觉得此问题之前一定已经得到解答,但经过多次搜索后我似乎无法找到答案。
I have a feeling that this question must have been answered before, but after much searching I don't appear to be able to find the answer.
我们正在此处实施Exchange 2010服务,我们需要将现有邮件从之前的电子邮件服务移至Exchange。我们的目标是通过创建一个通过Exchange Web服务上传邮件的自定义工具来实现这一目标。
We're in the process of implementing a Exchange 2010 service here, and we will need to move our existing mail from our previous email service to Exchange. We're aiming to do this by creating a custom tool that uploads the messages via Exchange Web Services.
最初我的计划是通过冒充用户然后将邮件保存到相关文件夹。对于消息创建部分,我有类似的内容:
Initially my plan was to do this by impersonating the user and then save the message to the relevant folder. For the message creation part I have something like:
EmailMessage msg = new EmailMessage(_service);
EmailMessage msg = new EmailMessage(_service);
msg.MimeContent = content;
msg.MimeContent = content;
msg.Save(parentFolderID);
msg.Save(parentFolderID);
这样可行,但文件夹中的所有消息都会出现草稿。我想知道是否有办法让它们成为正常的信息?或者我可能在这里使用错误的项目类型?
This works, but all the messages in the folder appear to be drafts. I wonder if there is a way to make them normal messages? Or maybe I'm using the wrong sort of Item type here?
一切顺利,
Sam,
推荐答案
msg.SetExtendedProperty(new ExtendedPropertyDefinition(3591,MapiPropertyType.Integer),"1");
干杯
格伦
这篇关于使用Exchange 2010上的EWS在收件箱中创建电子邮件(而非草稿)。的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!