标题:[求助]如何改动这段关于OUTLOOK代码才可以发送附件呢!谢谢!
只看楼主
jicktom11
Rank: 1
等 级:新手上路
帖 子:14
专家分:0
注 册:2007-9-18
 问题点数:0 回复次数:1 
[求助]如何改动这段关于OUTLOOK代码才可以发送附件呢!谢谢!

请帮忙看看下面得代码。怎么改才可以将文件”E:\Eng Work Planning -IR.xls“作为附件发送!非常感谢!
Private Sub Command1_Click()
Dim xlApp As Excel.Application, xlBook As Excel.Workbook, xlSheet As Excel.Worksheet
Dim ret As String
Dim App As Object
Dim Itm As Object


Set xlApp = CreateObject("Excel.Application")
Set xlBook = xlApp.Workbooks.Open("E:\Eng Work Planning -IR.xls")
Set xlSheet = xlBook.Worksheets("LiWei")

Set App = CreateObject("Outlook.Application")
Set Itm = App.CreateItem(0)
With Itm
.Subject = "Work plan update"
.To = "jicktom11@163.com"
.Body = test
.Send
End With

xlBook.Save
xlApp.Quit
Set xlSheet = Nothing
Set xlBook = Nothing


End Sub

搜索更多相关主题的帖子: OUTLOOK 附件 代码 
2007-09-18 15:59
jicktom11
Rank: 1
等 级:新手上路
帖 子:14
专家分:0
注 册:2007-9-18
得分:0 
回复:(jicktom11)[求助]如何改动这段关于OUTLOOK代...

各位大侠,能帮帮忙吗?非常感谢!

2007-09-22 21:44



参与讨论请移步原网站贴子:https://bbs.bccn.net/thread-170947-1-1.html




关于我们 | 广告合作 | 编程中国 | 清除Cookies | TOP | 手机版

编程中国 版权所有,并保留所有权利。
Powered by Discuz, Processed in 0.419687 second(s), 8 queries.
Copyright©2004-2025, BCCN.NET, All Rights Reserved