delphi过滤字符串头部和尾部得到中间部分


本文整理自网络,侵删。

 var
sString: string;
iPos,iLen: integer;
begin
sString:= 'http://www.3464.com/article.asp?articleid=4750';
iLen:= Length(sString);
iPos:= Pos('/',sString);
if iPos=0 then
Exit;
sString:= Copy(sString, iPos+2,iLen-iPos);
iPos:= Pos('/',sString);
if iPos=0 then
Exit;
sString:= Copy(sString, 1,iPos-1);
end;

相关阅读 >>

Delphi java设置环境变量小工具

Delphi 调用ie隐藏的命令

Delphi 长文件路径转换短文件路径

Delphi写com+的心得体会

Delphi indy 组件包里的 idhttp 组件使用 get 方法下载文件限速的方法

datasnap服务器如何得到客户端的ip和端口

Delphi中updown组件的使用方法

Delphi 计算imei的校验位

Delphi 获取image.picture.data的数据

Delphi 得到 winrar 处理解压缩文件的返回值 ?

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



打赏

取消

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

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

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

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

评论

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