1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27
| procedure TFficheselect.Button1Click(Sender: TObject);
VAR
nl,i: integer;
begin
table1.open;
if messagedlg('Attention....Etes Vous Sure De Vouloir Supprimer',mtconfirmation,[mbyes,mbno],0)=mryes then
begin
nl:=clbox1.items.count-1;
for i:= 0 to nl do
begin
while not table1.eof do
begin
if (table1.FieldByName('Mat').asstring)=copy(clbox1.items[i],0,4)then
if (table1.fieldbyname('Annee').asstring=cb1.Text)then
if (table1.fieldbyname('Mois').asstring=cb2.Text)then
begin
if clbox1.checked[i] then
begin
table1.Delete;
end;
end;
end. |
Partager