|
Outlook Express에서 보내는 메일 서버 에서 인증 필요를 선택해야 합니다.
그래야 메일을 보낼 수 있습니다.
Indy 이용해서 SMTP이용해서 메일 보내려고 하는데
같은 메일 서버에 있는 계정으로는 메일이 잘 갑니다.
그런데 hanmail이나 orgio , korea.com 같은 다른 계정에 메일을 보내면 안갑니다.
아래는 여기서 얻은 인디 데모 MailClient에서 얻어온 소스입니다.
어떻게 설정해야 보낼수 있어요? 별짓 다해도 안되네요.
에러 메시지입니다.
Project BCB5_MailClient.exe raised exception class EIdProtocolReplyError with message
'550 5.7.1 Unable to relay for island33@hanmail.net'. Process stopped. Use Step or Run to
continue.
발생하는 위치는 Send하는 부분입니다. SMTP->Send(IdMsgSend);
다시 말하지만 내부로 보내는 것은 가고, 외부로 보낼때는 아래의 메시지가 뜹니다.
그리고 Outlook Express에서 보내는 메일 서버 에서 인증 필요를 선택해야 합니다.
이부분 해결이 안되고 있는것 같습니다.
switch (SmtpAuthType)
{
// {authentication settings}
case 0:
SMTP->AuthenticationType = atNone;
break;
case 1:
SMTP->AuthenticationType = atLogin; //{Simple Login}
break;
};
// SMTP->UserID = SmtpServerUser;
SMTP->UserId = SmtpServerUser;
SMTP->Password = SmtpServerPassword;
// {General setup}
SMTP->Host = SmtpServerName;
SMTP->Port = SmtpServerPort;
// {now we send the message}
SMTP->Connect();
try
{
SMTP->Send(IdMsgSend);
}
catch(...)
{
}
SMTP->Disconnect();
|