delphi 去除 TStringList 重复项
2022-12-24 14:33:13 作者:admin
本文整理自网络,侵删。
//去除 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 获取网卡mac代码可用2020.01.22
Delphi线程中动态创建ado控件
Delphi 实现 托动pagecontrol上的标签页
Delphi ttabcontrol
Delphi中如何控制webbrowser滚动条
Delphi tmemo 可以显示、编辑多行文本
Delphi getfilehashmd5获取文件 hashmd5值
Delphi获取外部程序菜单并模拟点击菜单
Delphi 获取unixtime
Delphi extractfileext() 获取文件后缀的函数
更多相关阅读请进入《Delphi》频道 >>
猜你喜欢
联络方式:
400-123-789
邮箱:xiachao@163.com
Q Q:12345678
微信公众号
微信二维码
