Autor Beitrag
majolo
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 334

Ubuntu 8.04, WinXP Prof.
D1, D6Pers, D7 Prof., D8 Prof., D2005 Pers
BeitragVerfasst: Do 11.09.08 14:12 
Hallo zusammen,

ich möchte gerne in einem StringGrid jede zweite Zeile löschen. Eine einzelne Zeile löschen ist kein Problem, aber durch das raufrücken der nächsten Zeile verfange ich mich irgendwie in der Schleifen Konstruktion. Irgendwie merke ich, dass ich lange nicht mehr programmiert habe. Das Problem ist für meine Begriffe sehr einfach, aber ich sehe gerade den Wald nicht ;-)

Vielen Dank

_________________
Gruß
majolo
elundril
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 3747
Erhaltene Danke: 123

Windows Vista, Ubuntu
Delphi 7 PE "Codename: Aurora", Eclipse Ganymede
BeitragVerfasst: Do 11.09.08 14:21 
räum das stringgrid von hinten auf mit einer downto-schleife auf:

for i:=maxeintrag to 1 do
if x mod 2 =0 then
lösche zeile;

so würde es denk ich gehen. so löscht er vom ersten eintrag aus gesehen jeden zweiten eintrag.

lg elundril

_________________
This Signature-Space is intentionally left blank.
Bei Beschwerden, bitte den Beschwerdebutton (gekennzeichnet mit PN) verwenden.
majolo Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 334

Ubuntu 8.04, WinXP Prof.
D1, D6Pers, D7 Prof., D8 Prof., D2005 Pers
BeitragVerfasst: Do 11.09.08 14:30 
Merci,

klar von hinten hättte ich zählen müssen. :roll:

_________________
Gruß
majolo