If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed.
I've written a program that sends an email to everyone on an Excel
spreadsheet mailing list. I want the user to be able to send themselves a "test" mail, to confirm that the contents and attachments are correct,
before sending to the whole list. Is there a way to get Outlook to find the current user's address to put in the To field? Something like:- Message.To = ME, where ME is the current user's address?
But i m not getting the appropriate results can anyone tell me how to to that?
Re: Problem in Sending a test email to sender's own account.
Code:
Sub x()
Dim olApp As Outlook.Application
Dim olMAPI As Outlook.Namespace
Set olApp = CreateObject("Outlook.application")
Set olMAPI = olApp.GetNamespace("MAPI")
MsgBox olMAPI.CurrentUser.Address
End Sub