delphi 截取绝对路径的文件名


本文整理自网络,侵删。

 {delphi 截取绝对路径的文件名。}
function ExtractFileName(Str: string): string;
var
i: Integer;
begin
Result := '';
for i := Length(Str) downto 1 do
begin
if Str[i] <> '\' then Insert(Str[i], Result, 0)
else Exit;
end;
end;

相关阅读 >>

如何在Delphi中禁用关于“返回值...可能未定义”的警告?

Delphi 反转内存的函数

Delphi tparallel并行性能测试

Delphi写console控制台程序

Delphi guid单元

Delphi idftp用法

Delphi研究之驱动开发篇(六)--利用section与用户模式程序通讯(上)

Delphi中对url进行编码和解码

Delphi 分割字符串 extractstrings

Delphi 给label1字加边的又一个算法

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



打赏

取消

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

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

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

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

评论

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