Autor Beitrag
man-u
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 28



BeitragVerfasst: Mi 20.04.05 15:17 
Kann mir einer vielleicht mal sagen, wie ich ein StringGrid clearen (reseten) kann.
Wäre nett.

Danke im voarraus.


Moderiert von user profile iconChristian S.: Topic aus CLX / Delphi Language (Object-Pascal) verschoben am Mi 20.04.2005 um 16:18
Heiko
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 3169
Erhaltene Danke: 11



BeitragVerfasst: Mi 20.04.05 15:27 
Mir ist nur eine Variante bekannt, und zwar die, das man jede Zelle durchgeht und ihren Inhalt löscht.
Varianten zum "reseten", wie es bei z.B. der ListBox gibt, scheint es beim StringGrid nicht zu geben. Zu mindestens habe ich den Befehl Clear noch in keinem Unterpunkt gefunden.


Zuletzt bearbeitet von Heiko am Do 21.04.05 05:35, insgesamt 1-mal bearbeitet
man-u Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 28



BeitragVerfasst: Mi 20.04.05 19:43 
Okay danke
Lannes
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 2352
Erhaltene Danke: 4

Win XP, 95, 3.11, IE6
D3 Prof, D4 Standard, D2005 PE, TurboDelphi, Lazarus, D2010
BeitragVerfasst: Mi 20.04.05 22:21 
Hallo,

dort findest Du das von Heiko vorgeschlagene und noch was schnelleres:
SwissDelphiCenter: ...ein Stringgrid leeren?

_________________
MfG Lannes
(Nichts ist nicht Nichts) and ('' <> nil ) and (Pointer('') = nil ) and (@('') <> nil )
Heiko
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 3169
Erhaltene Danke: 11



BeitragVerfasst: Do 21.04.05 05:37 
Wenn es StringGrid1.Rows[I].Clear gibt, wäre es nicht schneller wenn man StringGrid1.Cols[I].Clearc verwenden würde?
Normalerweise hat man ja mehr Reihen als Spalten, wodurch er dann weniger Schleifendurchläufe bräuchte.
man-u Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 28



BeitragVerfasst: Do 21.04.05 12:46 
Okay vielen dank funktioniert wunderbar