Jump to content
Fivewin Brasil

configuracao smtp hotmail


sistem

Recommended Posts

Tente:
{"@live.com",       "smtp.live.com",            25, .T. },;  // ou porta 995  (requer autenticação criptografada)
 
ou
 
{"@live.com",       "smtps.live.com",            25, .T. },;  // ou porta 995  (requer autenticação criptografada)

Verifique se a senha está correta mesmo, entrando no outlook.com. com o email e senha corretos.

abs

Link to comment
Share on other sites

Agora fiquei com esta duvida, se bem que das duas formas funciona, mas qual e mais

correta? cdoAuthenticationType: .T. 0 1 ou 2??




/*
//cdoAuthenticationType = 0 //No Authentication
cdoAuthenticationType = 1 //Basic Authentication
//cdoAuthenticationType = 2 //NTML Authentication
*/

LOCAL lAut := 1 // .T. // Duvida e .T. ou 0, 1, 2 ??

:Item( "http://schemas.microsoft.com/cdo/configuration/smtpauthenticate" ):Value := lAut


abs.


Link to comment
Share on other sites

  • 2 weeks later...
  • 4 weeks later...
Alguem pode testar?


Vejam para gmail.com: se funcionar, testar no outlook.com


GET ::AUTH SECTION "MAIL" ENTRY "AUTH" OF oIni DEFAULT 1

GET ::SSL SECTION "MAIL" ENTRY "SSL" OF oIni DEFAULT .T.




METHOD LoadIni( cFile ) CLASS TPresencia
Local oIni
INI oIni FILE ".\" + cFile
GET ::smtpServer SECTION "MAIL" ENTRY "SMTPSERVER" OF oIni DEFAULT ""
GET ::smtpPort SECTION "MAIL" ENTRY "PORT" OF oIni DEFAULT 25
GET ::sendusing SECTION "MAIL" ENTRY "SENDUSING" OF oIni DEFAULT 2
GET ::username SECTION "MAIL" ENTRY "USER" OF oIni DEFAULT ""
GET ::password SECTION "MAIL" ENTRY "PASSWORD" OF oIni DEFAULT ""
GET ::AUTH SECTION "MAIL" ENTRY "AUTH" OF oIni DEFAULT 1
GET ::SSL SECTION "MAIL" ENTRY "SSL" OF oIni DEFAULT .T.
GET ::TimerOut SECTION "MAIL" ENTRY "TIMEROUT" OF oIni DEFAULT 10
GET ::Copia_Oculta SECTION "MAIL" ENTRY "COPIAOCULTA" OF oIni DEFAULT ""
GET ::Con_Copia SECTION "MAIL" ENTRY "CONCOPIA" OF oIni DEFAULT ""
GET ::GENERIC_TEXT SECTION "MAIL" ENTRY "TEXTO" OF oIni DEFAULT ""
GET ::FROM SECTION "MAIL" ENTRY "FROM" OF oIni DEFAULT ""
GET ::CUERPO SECTION "MAIL" ENTRY "TEXTBODY" OF oIni DEFAULT ""
ENDINI

RETURN NIL

******************************************************************************************
METHOD SendMail() CLASS TPresencia
******************************************************************************************
Local oError, oEmailCfg, oEmailMsg , cFile

TRY
oEmailCfg := CREATEOBJECT( "CDO.Configuration" )
WITH OBJECT oEmailCfg:Fields
:Item( "http://schemas.microsoft.com/cdo/configuration/smtpserver" ):Value := ::smtpServer
:Item( "http://schemas.microsoft.com/cdo/configuration/smtpserverport" ):Value := ::smtpPort
:Item( "http://schemas.microsoft.com/cdo/configuration/sendusing" ):Value := ::sendusing // Remote SMTP = 2, local = 1
// smtpauthenticate
// 0 cdoAnonymous Perform no authentication.
// 1 cdoBasic Use the basic (clear text) authentication mechanism.
// 2 cdoNTLM Use the NTLM authentication mechanism.
:Item( "http://schemas.microsoft.com/cdo/configuration/smtpauthenticate" ):Value := ::AUTH // 0 , 1 ,2
:Item( "http://schemas.microsoft.com/cdo/configuration/smtpusessl" ):Value := ::SSL
:Item( "http://schemas.microsoft.com/cdo/configuration/sendusername" ):Value := ::username
:Item( "http://schemas.microsoft.com/cdo/configuration/sendpassword" ):Value := ::Password
:Item( "http://schemas.microsoft.com/cdo/configuration/smtpconnectiontimeout"):Value := ::TimerOut
:Update()
END WITH

CATCH oError
? "---->Error en la configuracion"
END

oError := NIL
TRY
oEmailMsg := CREATEOBJECT ( "CDO.Message" )
WITH OBJECT oEmailMsg
:Configuration = oEmailCfg
:From := ::FROM
:To := ::email // <----- Coloca tu dirección de correo
:CC := ::Con_Copia // Con copia
:BCC := ::Copia_Oculta // Con Copia Oculta
:Subject := ::Asunto // Asunto
// :MDNRequested = .T. // Solicitud de reconocimiento, o acuse de recibo
:TextBody := ::Cuerpo

for each cFile in ::aFiles
:AddAttachment( cfile )
next
:Fields:update()
:Send()
// ? "[ "+Time()+" ] Enviado correo :"+ ::email
END
CATCH oError
? "---->Error en el envio del mensaje:"+ oError:Description
END

oEmailCfg := NIL
oEmailMsg := NIL

SysRefresh()

Return .T.


Ou testar esta ferramenta do William, Morales:




Quem sabe...


abs.

Link to comment
Share on other sites

ao invés de 587, coloque 465

Já testei com 25, 465 e 587 e nada, Não vai. abs. É https? sim. e também com Não: http, e nada.

teste ai, criei este email de teste e está enviando de boa diretamente no provedor:

nfepleno@outlook.com
smtp-mail.outlook.com
está disponível.
a senha é 1234567br
abs.
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...