Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Sending HTML mail messages
Message
De
13/10/2003 07:55:37
 
 
À
13/10/2003 06:58:06
Information générale
Forum:
Visual FoxPro
Catégorie:
COM/DCOM et OLE Automation
Divers
Thread ID:
00838026
Message ID:
00838035
Vues:
24
>Hi,
>
>I got this sample code from message #611182:
>
>oOutlookApp = createobject('outlook.application')
>oMailItem = oOutlookApp.createitem(0)
>
>with oMailItem
>	.HTMLBody = "Here comes the HTML code"
>	.subject = "Here comes the subject"
>	.to = "myemail@myorg.com.br"
>	.send()
>endwith
>
>When I try to run it I get an "OLE error code 0x80020006: unknown name" error in the line containing the ".HTMLBody = "Here comes the HTML code"". If I comment that line it works ok.
>
>What am I missing?
>
>TIA
>
>Fernando

Fernando, this example works for me as is using Outlook 2002 SP2 on Winxp. What version of outlook are you running? Have you got intellisense on - use it and enter the above commands in the command window one by one and it will tell you what properties and methods your instance of oMailItem supports. Check that HTMLBody is valid property.

hth
In the End, we will remember not the words of our enemies, but the silence of our friends - Martin Luther King, Jr.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform