Ich sende eine E-Mail mit dem QTP Outlook Objektmodell.QTP, Adresse senden
Hier ist das Stück Code.
'Create an object of type Outlook
Set objOutlook = CreateObject("Outlook.Application")
Set myMail = objOutlook.CreateItem(0)
'Set the email properties
myMail.To = "[email protected]"
myMail.CC = "[email protected]; [email protected]" 'Sending mails to multiple ids
myMail.BCC = "" 'If BCC is not required, then this line can be omitted
myMail.Subject = "Sending mail from MS Outlook using QTP"
myMail.Body= "Test Mail Contents"
myMail.Attachments.Add("D:\Attachment.txt") 'Path of the file to be attached
'Send the mail
myMail.Send
Jetzt brauchte ich den Absender E-Mail-Adresse & speichern es in einer Umgebungsvariablen abzurufen. myMail.Sender
oder myMail.sendermailaddres
beide arbeiten mich nicht.