开发者

Get filename from full path in Pascal

开发者 https://www.devze.com 2023-03-07 17:43 出处:网络
I\'m wondering how to get a file name from full path in Pascal. In .NET, we have two functions - Path.GetFileName and String.IndexOf, both of them allow to accomplish the task.开发者_如何学JAVA

I'm wondering how to get a file name from full path in Pascal.

In .NET, we have two functions - Path.GetFileName and String.IndexOf, both of them allow to accomplish the task.开发者_如何学JAVA

For example, "C:\docs\file.txt" will return "file.txt".

What would be the Pascal equivalent?


It is the ExtractFileName function. Thanks to Ken's comment.

0

精彩评论

暂无评论...
验证码 换一张
取 消