Results 1 to 2 of 2

Thread: MS Outlook auto-reply

  1. #1

    Thread Starter
    New Member
    Join Date
    Jul 2002
    Location
    Coventry, UK
    Posts
    1

    Question MS Outlook auto-reply

    I am writing an application that needs to read an email and then reply to the sender. Reading and writing are fine except I don't know how to reply. I can write a new email but I don't know the email address to write to, all I know is the sendername and therefore I can't write to them without knowing their address. Does anybody know how to get the senders' email address out of outlook or reply to a message with custom text?

    Any information gratelfully received.

    thanks.

    Graham

    [email protected]
    Graham./

  2. #2
    New Member
    Join Date
    Jul 2002
    Posts
    12

    Automating Outlook

    Here is a snippet for automating outlook for the reply.

    Don't know if you are precluded from doing this. If you are, you need to get to the MAPI layer - post back if still no joy.

    Dim objOutlook As New Outlook.Application
    Dim objOutlookMsg As Outlook.MailItem

    'Create new message
    Set objOutlookMsg = objOutlook.CreateItem(olMailItem)

    With objOutlookMsg
    .To = "[email protected]"
    .Subject = "My Reply Subject"
    .Body = "Dear Customer" & vbNewLine & vbNewLine
    .Body = .Body & "Here is my reply "
    .Importance = olImportanceHigh
    .Send
    End With

    Set objOutlookMsg = Nothing

    Set objOutlook = Nothing

    [email protected]

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width