server üzerinde bir web sayfamız var ve serverin bir klasörünün altındak,i dosyalar her gün yeni ekelentilerle çoğalıyor bu durumda bende hergün manual olarak html sayfayı update etmek zorunda kalıyorum buna bir çözüm olarak aşağıdaki kodu yazdım
Kod: Tümünü seç
procedure TForm1.Button1Click(Sender: TObject);
var
DirInfo: TSearchRec;
r,x : Integer;
begin
x:=0;
r:=0;
r := FindFirst('\\ada\d$\Inetpub\wwwroot\data\engine\Airbus\TC_KTD\engine cruise report\engine1\*.xls', FaAnyfile, DirInfo);
while r = 0 do
begin
x:=x+1;
ComboBox1.Items.Add(pChar('\\ada\d$\Inetpub\wwwroot\data\engine\Airbus\TC_KTD\engine cruise report\engine1\' + DirInfo.Name));
r := FindNext(DirInfo);
end;
showmessage(inttostr(x)+' adet dosya bulundu');
end;
Kod: Tümünü seç
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Certificates Frame</title>
<style type="text/css">
<!--
body {
background-color: #FFCC33;
}
-->
</style>
</head>
<body>
<table width="353" border="1">
<tr>
<td width="266" background="CertificatesFrame.html"><p align="center"><strong>TC-KTD Engine Cruise Reports #1</strong><strong>(Fuel Flow Per Hour)</strong></p> </td>
<td width="71" background="CertificatesFrame.html">Doc. Type</td>
</tr>
<tr>
<td background="../Index.html"><a href="data/engine/Airbus/TC_KTD/engine cruise report/engine1/TC_KTD ENG1 fuel flow 20070904.xls" target="_blank">20070904</a></td>
<td background="../Index.html"><div align="center"><img src="pictures/Excel_2003.png" width="32" height="32" /></div></td>
</tr>
</table>
<p> </p>
<p> </p>
</body>
</html>
Kod: Tümünü seç
<tr>
<td background="../Index.html"><a href="data/engine/Airbus/TC_KTD/engine cruise report/engine1/TC_KTD ENG1 fuel flow 20070904.xls" target="_blank">20070904</a></td>
<td background="../Index.html"><div align="center"><img src="pictures/Excel_2003.png" width="32" height="32" /></div></td>
</tr>
alanı dosyaların siimlerinin olduğu yerler ve ben bunun olması gerekekn yere combobox1 listesinini ekleyerek çoğaltmalıyım ve dosyamıda otomatik olarak save etmeliyim bu durumda bu kod nasıl olmalı.
bu arada html dosyamın ismi ise TC_KTD_no1 _EngineCruieReports2.html şeklindedir.
şimdiden tüm arkadaşlara teşekkür ederim...