![]() | |
| | #2 (permalink) |
| Üye Üyelik Tarihi: 06/2004
Mesaj: 67
|
ben bu şekilde yapmıştım. burası biraz karışık gibi görünüyor ama maildeki eki nasıl alman gerektiğini burdan çıkartabilirsin.... procedure TThread1.RetrievePOPHeaders(MesajSayisi: Integer); var stTemp: string; intIndex,intindex2: integer; itm: TListItem; DosyaAdi,DosyaPath, FirmaKodu : String; Tarih:_systemtime; Kaydet:TFileName; begin ToplamBoyut:=0; GetSystemTime(Tarih); form1.Label9.Caption:='Toplam Gelen E-Posta Sayısı:' + inttostr(MesajSayisi); for intIndex := 1 to MesajSayisi do begin idMessage2.Clear; idPOP32.RetrieveHeader(intIndex, idMessage2); If IdMessage2.Subject = 'XXXX' Then Begin itm := Form1.ListView1.Items.Add; itm.Caption := IdMessage2.Subject; itm.SubItems.Add(IntToStr(idPOP32.RetrieveMsgSize( intIndex))); itm.SubItems.Add(inttostr(intIndex)); itm.SubItems.Add(' '); ToplamBoyut := ToplamBoyut + idPOP32.RetrieveMsgSize(intIndex); End; //if end; //for form1.Label1.Caption := 'Gelen Veri Sayısı:' + IntToStr(Form1.ListView1.Items.Count); form1.Label2.Caption := 'Toplam Boyut:'+inttostr(ToplamBoyut)+' Byte'; Toplam := form1.ListView1.Items.Count; for intIndex := 0 to form1.ListView1.Items.Count - 1 Do Begin form1.Memo1.Lines.Add('Veri Dosyaları Ayıklanıyor...'); Alinan := intindex+1; Synchronize(alinanmail); idPOP32.Retrieve(StrToInt(form1.ListView1.Items[intIndex].SubItems.Strings[1]), idMessage2); for intIndex2 := 0 to Pred(idMessage2.MessageParts.Count) do begin if (idMessage2.MessageParts.Items[intIndex2] is TIdAttachment) then begin DosyaAdi :=TIdAttachment(idMessage2.MessageParts.Items[intIndex2]).Filename; FirmaKodu := Copy(DosyaAdi,1,Pos(' and ',DosyaAdi)-1); Form1.ListView1.Items[intIndex].SubItems.Strings[2] := FirmaKodu; DosyaPath :=ExtractFilePath(Application.ExeName) +'Firma\' + FirmaKodu + '\' + inttostr(tarih.wYear) + '\'; form1.Memo1.Lines.Add(DosyaAdi); if Not DirectoryExists(DosyaPath) Then Begin if Not DirectoryExists(ExtractFilePath(Application.ExeNam e)+'firma') Then CreateDir(ExtractFilePath(Application.ExeName)+'fi rma'); If Not DirectoryExists(ExtractFilePath(Application.ExeNam e)+'firma\' + FirmaKodu) Then CreateDir(ExtractFilePath(Application.ExeName)+'fi rma\'+FirmaKodu); CreateDir(DosyaPath); End; Kaydet := DosyaPath+DosyaAdi; If FileExists(DosyaPath+DosyaAdi) Then DeleteFile(DosyaPath+DosyaAdi); form1.Label9.Caption :='Veri Dosyası Bilgisayarınıza Kaydediliyor...'; ---------------> If Not TIdAttachment(idMessage2.MessageParts.Items[intindex2]).SaveToFile(Kaydet) Then begin MsgId:=3; Synchronize(UpdateProgressBar); Exit; End; end; End; form1.Gauge1.Progress := 100; if form2.CheckBox1.Checked Then Begin form1.Label9.Caption :='Veri Dosyası Sunucudan Siliniyor...'; IdPop32.Delete(StrToInt(form1.ListView1.Items[intIndex].SubItems.Strings[1])); End; End; end; |
| | |
![]() |
| Bookmarks |
| Seçenekler | |
| |
Benzer Konular | ||||
| Konu | Konuyu açana göre | Forum | Cevap | En Son Mesaj |
| php mail ile hotmail gelen kutusunda mail göndermek | dvdbil | PHP | 24 | 07/04/2008 05:59 |
| Form u Mail Olarak alma | emreberk | ASP | 1 | 17/12/2006 10:07 |
| Pop3 mail, mailleri serverdan alma | sali | ASP | 1 | 19/10/2005 18:48 |
| Mail Formdan saldırı... 968 mail geldi.. Hala devam ediyor | ertugrul999 | PHP | 16 | 20/07/2005 21:10 |
| Merak Mail Server veya Mail gönderememe problemi | hgumus | Internet | 19 | 29/06/2005 09:52 |
| Reklamlar & Desteklenenler | |
| Hassas Valf | Hassas Kaplama | Antalyamız | Gazete | Ticari Bilişim | Hakan Müştak | Rüya Tabirleri | Kadın | Hastalıklar | Cepte msn ve e-posta | Webmaster | Antalya Aupair | Turkish Property Antalya | Forum | Chat | Perde | Adsl | Araba | bolindir.com | guncelle.com | livescore | Web Tasarım | evden eve nakliyat | forum | evden eve | sohbet | Resimcim| Kalifiye İnsan Kaynakları | Web Tasarım | Oyun | Yusuf KOÇ | Akın Yorulmaz | şiir | UFO | Web Tasarım | Oyunlar | Canlı Tv | |