I am newbie in the Hub. I need help from you guys.
I have created macro to send mail draft along with attachment from mentioned location. I know only small changes in macro.
Please help to resolve the below mentioned query in the Macro.
1. My outlook format is HTML. When I run the macro it will automatically change to plain text and not included my signature in draft. I need mail draft mail in HTML format and signature.
2. I have given the files / person name in excel file. If the file name not in the location it is not working. I need to use if condition in coding.
Query is given below - using Excel 2000
Sub Mail()
Worksheets("Draft Mail").Select
Range("b16").Select
Do Until ActiveCell = "Finish"
Dim objOutlook As Object
Dim OutApp As Object
Dim OutMail As Object
Dim strbody As String
Dim SigString As String
Dim Signature As String
Dim emlHTMLBody, sendTo As String
Dim wkbook As String
Application.ScreenUpdating = False
Set objOutlook = CreateObject("Outlook.Application")
Set objMailMessage = objOutlook.CreateItem(0)
SigString = "C:\Documents and Settings\Mohandhas.Gnanasekar\Desktop\New.htm"
With objMailMessage
.To = ActiveCell
.CC = ActiveCell.Offset(0, 1)
.Subject = ActiveCell.Offset(0, 2)
.body = ActiveCell.Offset(0, 3)
.Attachments.Add "C:\Documents and Settings\Mohandhas.Gnanasekar\Desktop\Process\Remainder Mail\Mail\" & ActiveCell.Offset(0, -1) & ".xls"
.Save
.Close olPromtForSave
End With
ActiveCell.Offset(1, 0).Select
Loop
End Sub
Bookmarks