感谢您使用微软产品。您可以试一下类似于以下的代码,希望能有所帮助。
MailMessage oMsg = new MailMessage();
oMsg.From = "[email protected]";
oMsg.To = "[email protected]";
oMsg.Subject = "Send using Web Mail";
oMsg.Body = "Hello World";
String sFile = "g:\\abc1.doc";  // TODO:
MailAttachment oAttch = new MailAttachment(sFile, MailEncoding.Base64);
        oMsg.Attachments.Add(oAttch);
oMsg.Priority = MailPriority.High;
SmtpMail.Send(oMsg);
oMsg = null;
oAttch = null;- 微软全球技术中心 VB技术支持本贴子仅供CSDN的用户作为参考信息使用。其内容不具备任何法律保障。您需要考虑到并承担使用此信息可能带来的风险。具体事项可参见使用条款(http://support.microsoft.com/directory/worldwide/zh-cn/community/terms_chs.asp)。
为了为您创建更好的讨论环境,请参加我们的用户满意度调查(http://support.microsoft.com/directory/worldwide/zh-cn/community/survey.asp?key=(S,49854782))。