¬°¦ó°õ¦æexcel vba¤§«á«H¥ó¤´°±¦boutlook±H¥ó§¨©O¡H
- ©«¤l
- 231
- ¥DÃD
- 55
- ºëµØ
- 0
- ¿n¤À
- 293
- ÂI¦W
- 0
- §@·~¨t²Î
- winxp
- ³nÅ骩¥»
- office2003
- ¾\ŪÅv
- 20
- ©Ê§O
- ¨k
- ¨Ó¦Û
- KEELUNG
- µù¥U®É¶¡
- 2010-7-24
- ³Ì«áµn¿ý
- 2018-8-28
|
¬°¦ó°õ¦æexcel vba¤§«á«H¥ó¤´°±¦boutlook±H¥ó§¨©O¡H
¦U¦ì¤j¤j¦n¡G
¤p§Ì§Q¥ÎEXCEL VBA¤è¦¡E-MAIL
¤å¥ó¸ê®Æ¨ÃÀHªþÀɮסC¥i¬O«oµo²{°õ¦æ¤§«á¡F
¸ÓE-MAIL«H¥ó¸ê®Æ¤´°±¯d¦bOUTLOOK±H¥ó§¨¤º¡C
«Dn¥h¶}±ÒOUTLOOK¦A«ö°õ¦æ±H¥óªº°Ê§@¤~·|
±N¦¹«H¥ó±H°e¥X¥h©O¡H
'outlook 2002ª©¥»
'excel 2002ª©¥»
Sub SendWithAtt()
'¤Þ¥ÎMicrosoft outlook object library
Dim olApp As Outlook.Application
Dim olMail As MailItem
Dim CurrFile As String
Set olApp = New Outlook.Application
Set olMail = olApp.CreateItem(olMailItem)
CurrFile = "d:\temp\test.txt"
With olMail
.To = "[email protected]"
.Subject = "These one files"
.Body = "´ú¸Õ«H¥ó"
.Attachments.Add CurrFile
'.Display
.Send
End With
Set olMail = Nothing
Set olApp = Nothing
End Sub
·PÁ¦U¦ì¤j¤j¡C |
|
|
|
|
|
|
- ©«¤l
- 231
- ¥DÃD
- 55
- ºëµØ
- 0
- ¿n¤À
- 293
- ÂI¦W
- 0
- §@·~¨t²Î
- winxp
- ³nÅ骩¥»
- office2003
- ¾\ŪÅv
- 20
- ©Ê§O
- ¨k
- ¨Ó¦Û
- KEELUNG
- µù¥U®É¶¡
- 2010-7-24
- ³Ì«áµn¿ý
- 2018-8-28
|
ÁÂÁ¤j¤j¡C
¤p§Ì¤Þ¥Î¤U»yªk
¤w¥i¹F¦¨e-mail¤F¡C
'Microsoft CDO for Windows 2000 Library
Private Sub CommandButton1_Click()
Dim mPath As String
Dim mFilename As String, mFile$
Dim mStr$
Dim myMail As Object
mPath = "D:\temp\"
mFilename = TextBox1.Text
If Len(mFilename) = 0 Then
MsgBox "½Ð¥ý¿é¤J«È¤á½s¸¹"
Exit Sub
End If
mFile = mPath & mFilename & ".pdf"
mStr = Dir(mFile)
If Len(mStr) = 0 Then
MsgBox "¿é¤JÀɦW¤£¦s¦b" & vbCrLf & vbCrLf & "½Ð«·s¿é¤JÀɦW"
Exit Sub
End If
Set myMail = CreateObject("CDO.Message")
myMail.BodyPart.Charset = "big5"
myMail.Subject = "KUOZUI MOTORS LTD" & mFilename
myMail.Subject = "CUSTOMER CORP" & mFilename
myMail.From = "[email protected]"
myMail.To = "[email protected]"
myMail.CC = "[email protected]"
myMail.TextBody = "AUTO PARTS"
myMail.AddAttachment (mFile)
myMail.Send
Set myMail = Nothing
TextBox1.Text = ""
TextBox1.SetFocus
End Sub |
|
|
|
|
|
|
- ©«¤l
- 231
- ¥DÃD
- 55
- ºëµØ
- 0
- ¿n¤À
- 293
- ÂI¦W
- 0
- §@·~¨t²Î
- winxp
- ³nÅ骩¥»
- office2003
- ¾\ŪÅv
- 20
- ©Ê§O
- ¨k
- ¨Ó¦Û
- KEELUNG
- µù¥U®É¶¡
- 2010-7-24
- ³Ì«áµn¿ý
- 2018-8-28
|
·PÁ¤j¤j¡C
¤p§Ì¥ý¦¬¤U
¸Õ¸Õ¡C
·P®¦¡I |
|
|
|
|
|
|
- ©«¤l
- 133
- ¥DÃD
- 9
- ºëµØ
- 0
- ¿n¤À
- 147
- ÂI¦W
- 0
- §@·~¨t²Î
- Win10
- ³nÅ骩¥»
- Office 2010
- ¾\ŪÅv
- 20
- ©Ê§O
- ¨k
- ¨Ó¦Û
- °ª¶¯
- µù¥U®É¶¡
- 2010-5-1
- ³Ì«áµn¿ý
- 2024-11-11
|
|
|
|
|
|
|