Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Is it possible to send email over the Internet
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Versions des environnements
Visual FoxPro:
VFP 9 SP2
OS:
Windows Server 2012
Network:
Windows 2008 Server
Database:
MS SQL Server
Application:
Web
Divers
Thread ID:
01619313
Message ID:
01619344
Vues:
55
To use cdo2000
LOCAL loMail as cdo2000 OF cdo2000.prg
loMail = NEWOBJECT("Cdo2000", "Cdo2000.prg")

loMail.cServer="smtp.someserver.com"
loMail.nServerPort=25
loMail.lUseSSL=.F.
loMail.nAuthenticate=1
loMail.cUserName="username"
loMail.cPassword="password"
loMail.cFrom="you@you.com"
loMail.cTo="him@him.com"
loMail.cCC=""
loMail.cSubject="email subject"
loMail.cTextBody="email body"

IF loMail.send()>0
	LOCAL lcErrorMsg,lnX
	lcErrorMsg=""
	FOR lnX=1 TO loMail.GetErrorCount()
		lcErrorMsg=lcErrorMsg+loMail.Geterror(lnX)+" "
	ENDFOR
	* Clear errors
	loMail.ClearErrors()
	
ENDIF
Brandon Harker
Sebae Data Solutions
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform