A r t i c l e s
Navigation

Note: This site is
a bit older, personal views
may have changed.

M a i n P a g e

D i r e c t o r y

StringList Tips


Some tips when working with stringlists
Dealing with duplicates in the list
 test:=tstringlist.create;
 test.Sorted:=true;  //must have this set for duplicate settings to work
 test.Duplicates:=dupIgnore;
 test.Add('yada124');
 test.Add('yada2');
 test.Add('yada');
 test.Add('yada2');
 test.Add('yada');
 test.Add('yada21');
 test.Add('yada33');
 test.Add('yada2');
 test.Add('yada2');
 test.Add('yada232');
 test.Add('yada345');
 test.Add('yada2');
 //test.Duplicates:=dupIgnore; //not correct here, place before a adding
 memo1.Text:= test.Text;
 test.free; test:=nil;



About
This site is about programming and other things.
_ _ _