Stringgrid delete row

cs_saravana Messages postés 91 Date d'inscription vendredi 25 mars 2005 Statut Membre Dernière intervention 18 octobre 2007 - 21 nov. 2005 à 18:03
cs_Adkiks Messages postés 40 Date d'inscription jeudi 20 mai 2004 Statut Membre Dernière intervention 29 janvier 2006 - 26 nov. 2005 à 16:49
bjr;
comment supprimer une ligne séléctionnée dans un stringgrid
j'ai fé ma petite recheche le code proposé ne fonctionne pas!
++
A voir également:

3 réponses

DRJEROME Messages postés 436 Date d'inscription jeudi 9 janvier 2003 Statut Membre Dernière intervention 5 février 2015
21 nov. 2005 à 21:54
<HR>
procedure DeleteRow(SG:TStringGrid;Row:integer);
var
i:integer;
begin
if (SG.RowCount-1>Row) and (Row>0) and (SG.RowCount>1) then
begin
for i:=Row+1 to SG.RowCount-1 do SG.Rows[i-1].Assign(SG.Rows[i]);
SG.RowCount:=SG.RowCount-1;
end;
end;

<HR>


N'oubliez pas de cliquer sur Réponse acceptée si c'est OK

DrJerome
0
Rejoignez-nous