本文整理自网络,侵删。
//去除 TStringList 重复项procedure RemoveDuplicates(const AStrs: TStringList);var Buf: TStringList; Idx: Integer;begin AStrs.Sort; Buf := TStringList.Create; try Buf.Sorted := True; Buf.Duplicates := dupIgnore; Buf.BeginUpdate; for Idx := 0 to AStrs.Count - 1 do begin Buf.Add(AStrs[Idx]) ; end; Buf.EndUpdate; AStrs.Assign(Buf) ; finally FreeandNil(Buf) ; end;end;
http://www.delphifmx.com/node/29 相关阅读 >>
Delphi 一个绘制虚线的非常规函数(常规方法,打印机上绘制不出虚线)
Delphi显示 jpg、png、gif 图片及 gif 动画
Delphi android device information
更多相关阅读请进入《Delphi》频道 >>