merhaba arkadaslar; forumda epeydir arama da yaptım farklı arkadasların yazmıs oldugu kodları da denedim ama bir turlu smtp ile pop3 adresimi kullanarak mail atmayı beceremedim. asagıdaki kodda herhangi bir problem var mı denemeleri yaptım fakat sorunun nerede oldugunu bulamadım. eger tek kişiye mail atmayı becerebilirsem toplu mail gönderimine gecebilecegim yardımcı olursanız sevinirim.
unit Unit1;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, StdCtrls, IdMessage, IdBaseComponent, IdComponent,
IdTCPConnection, IdTCPClient, IdMessageClient, IdSMTP;
type
TForm1 = class(TForm)
IdSMTP1: TIdSMTP;
IdMessage1: TIdMessage;
Button1: TButton;
Memo1: TMemo;
procedure Button1Click(Sender: TObject);
// procedure ReadConfiguration;
private
{ Private declarations }
public
{ Public declarations }
end;
var
Form1: TForm1;
implementation
{$R *.dfm}
procedure TForm1.Button1Click(Sender: TObject);
begin
try
//ReadConfiguration;
IdMessage1.MessageParts.Clear;
//TIdAttachment.Create(IdMsgSend.MessageParts, rutt);
application.ProcessMessages;
with IdMessage1 do
begin
body.Clear;
From.Text := 'serkan.isik@avm.com.tr';
Recipients.EMailAddresses := 'serkan.isik@avm.com.tr';
Subject := 'Taksit hatırlatıcı '+datetostr(date)+' '+timetostr(time);
body.Text:=memo1.text;
Priority := mpNormal;
CCList.EMailAddresses := '';
BccList.EMailAddresses := '';
ReceiptRecipient.Text := '';
end;
IdSMTP1.Username := 'serkan.isik';
IdSMTP1.Password := '100341';
IdSMTP1.Host := 'mail.avm.com.tr';
IdSMTP1.Port := 25;
IdSMTP1.Connect;
except;
end;
try
IdSMTP1.Send(IdMessage1);
IdSMTP1.Disconnect;
finally
IdSMTP1.Disconnect;
end;
{procedure Tform1.ReadConfiguration;
begin
SmtpServerName := 'mail.konat.net';
SmtpServerPort := 25;
SmtpServerUser := 'sipdorus';
SmtpServerPassword := 'şirfem';
SMTP.AuthenticationType:=atlogin;
UserEmail := 'sipdorus@konat.net';
end; }
end;
end.
smtp kullanarak mail gönderme de problem
Forum kuralları
Forum kurallarını okuyup, uyunuz!
Forum kurallarını okuyup, uyunuz!
kodu pascal kuralalrına göre yolalrmısınız blokları kontrol edemiyorum böyle.
Kişi odur ki, koyar dünyada bir eser. Eseri olmayanın yerinde yeller eser./Muhammed Hadimi
http://www.ibrahimkutluay.net
http://www.ibrahimkutluay.net/blog
http://www.ibrahimkutluay.net
http://www.ibrahimkutluay.net/blog