Estimados, estoy renegando con mandar un mail desde mi aplicacion y me sale este error, si alguien sabe , se los agradeceria: Trabajo en Delphi 7 y indy 9 en una maq de con Win 8 de 64 bit .
http://www.clubdelphi.com/foros/atta...1&d=1429021841
y este es el codigo
Código Delphi
[-]
with mailMensaje do
begin
Body.Clear();
Recipients.Clear();
Sender.Address := 'xxxxx@gmail.com';
Recipients.EMailAddresses := 'xxxxx@hotmail.com';
Subject := 'vamossss';
Body.SetText(PChar(str));
end;
with indySMTP do
begin
IOHandler := IdSSLIOHandlerSocket1;
IdSSLIOHandlerSocket1.SSLOptions.Method := sslvSSLv23; IdSSLIOHandlerSocket1.SSLOptions.Mode := sslmUnassigned;
IdSSLIOHandlerSocket1.SSLOptions.VerifyMode := [];
IdSSLIOHandlerSocket1.SSLOptions.VerifyDepth := 0;
Port := 465;
Host := 'smtp.gmail.com';
AuthenticationType := atLogin;
Username := 'xxxxx@gmail.com';
Password := 'xxxxxx';
try
Connect(5000);
except
ShowMessage('Error de conexión');
end;
btnEnviarEmail.Enabled := false;
try
Send(mailMensaje);
ShowMessage('Correo enviado con éxito');
finally
btnEnviarEmail.Enabled := true;
end;
if Connected then
Disconnect();
end;
Muchas Gracias.