Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Outlook & MailLists
Message
 
À
Tous
Information générale
Forum:
Visual FoxPro
Catégorie:
COM/DCOM et OLE Automation
Titre:
Outlook & MailLists
Divers
Thread ID:
00401749
Message ID:
00401749
Vues:
69
I try to create a new distribution list to Outlook from VFP6. I can create the distribution list, but I'm not able to fill it with members - e-mail addresses. Here's my code:

m.oTempMailItem=ThisForm.oOutlook.Createitem(0)
m.oRecipients=m.oTempMailItem.Recipients

m.oDstList=m.destFolder.Items.Add(7) && 7 = Distrib.list
with m.oDstList
.DLName=alltrim(ThisForm.Container1.TextBox_1.Text)
select address
scan
m.oNewRep=m.oRecipients.Add(allt(address.CompanyName))
m.oNewRep.Address=allt(address.EmailAddress)
endscan
.AddMembers(m.oRecipients)
.Save() && this finally saves the distribution list to Outlook
endwith

I can't assign the recipient's name. When I add a new member manually in Outlook, I can see it within the recipient object, but can't change it from FoxPro.
What am I doing wrong?
Thanks in advance for any ideas.
Répondre
Fil
Voir

Click here to load this message in the networking platform