delphi 字符串的分割


本文整理自网络,侵删。

  C#
**************
string strList='A,B,C,D';
string[] strArray=strList.Split(new Char[]{','});
//这里strArray里有4个元素,各自分别为:'A' , 'B' , 'C' , 'D'。

Delphi
**************
procedure StringSplit(const Delimiter : char; Input : string; const Strings : TStrings);
begin
  Assert(Assigned(Strings));
  Strings.Clear;
  Strings.Delimiter := Delimiter;
  Strings.DelimitedText := Input;
end;

相关阅读 >>

Delphi 清除windows 图标缓存源代码

Delphi删除文件和文件夹

Delphi xe2 idhttp 获取utf-8编码中文网页

Delphi 删除目录下指定类型文件

Delphi 运行js

Delphi 实现软件版验证码

Delphi twebbrowser 设置焦点

Delphi xe2模拟键盘按键

Delphi 如何取得系统中的桌面的路径

Delphi 同时激活两个窗体

更多相关阅读请进入《Delphi》频道 >>



打赏

取消

感谢您的支持,我会继续努力的!

扫码支持
扫码打赏,您说多少就多少

打开支付宝扫一扫,即可进行扫码打赏哦

分享从这里开始,精彩与您同在

评论

管理员已关闭评论功能...