delphi String转换成TStrings


本文整理自网络,侵删。

 

function StringsToStr(const vList:TStrings):string;
var
  i:Integer;
begin
  Result := '';
  for i:=0 to vList.Count-1 do
  begin
    if Result <> '' then
      Result := Result+'#'+vList.Strings[i]
    else
      Result := vList.Strings[i];
  end;
end;

//String转换成TStrings
function StrToStrings(const Str:string;var vList:TStrings):Integer;
begin
  Result := ExtractStrings(['#'],[' '],PChar(str),vList);
end;

相关阅读 >>

Delphi和outputdebugstring

Delphi strutils.leftstr、strutils.rightstr - 提取左右字符串

Delphi base24编码解码

Delphi winapi: openprocess、getexitcodeprocess、terminateprocess (qq)

Delphi 字符串查找替换函数

Delphi sqlite防止插入重复数据的方法

Delphi (user agent) of a twebbrowser

Delphi idtcp下载文件

Delphi通过url获取网页源码

Delphi 获取其他进程句柄的几种方法

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



打赏

取消

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

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

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

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

评论

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