projemde güncelleme için internetten zip dosyası indirtip, bunu cmd ile unzip ediyorum.
program çalışıyor ama dosya indirilirken gauge üzerinde indirme durumunu gösteremiyorum.
sorunun detayına indiğimde IdHTTP1WorkBegin ve IdHTTP1Work olaylarının çalışmadığını fark ettim, (showmessage ile olayları denedim çalışmadı)
sizce bunun nedeni ne olabilir.
Kod: Tümünü seç
procedure TGirisForm.Guncelle();
begin
sayfalar.activepage:='download';
dosya:=tfilestream.create(ExtractFilePath(Application.Exename)+'xxx.zip',fmcreate);
try
idhttp1.get(GUNCEL_SURUM_INDIR , dosya);
finally
.......
.......
Kod: Tümünü seç
procedure TGirisForm.VersiyonKontrol;
begin
if GUNCEL_SURUM_NO > EXE_SURUM then
begin
if Application.MessageBox(PWidechar('Yeni Bir Güncelleme Mevcut, İndirilsin Mi?'+#13+'Versiyon Bilgileri;'+#13+QuotedStr(GUNCEL_SURUM_ACIKLAMA)),'Uygulamanız Güncel Değil!',MB_YESNO+MB_ICONQUESTION)=6 then
begin try Application.ProcessMessages; guncelle(); Application.ProcessMessages; except on E:Exception do
begin SQLLog(fdquery1.FieldByName('user_data_kullanici').Asstring,'HATA',E.Message); raise Exception.Create('HATA: '+E.Message);
end; end; girisform.show;
SQLLog(fdquery1.FieldByName('user_data_kullanici').Asstring,'PROGRAM','Program Güncelleme Talimatı Verildi!'); end;
end;
end;