IOS从路径中获取文件名
2016-09-03 本文已影响65人
蜗牛1992
+(NSString*) GetFileName:(NSString*)pFile
{
NSRange range = [pFile rangeOfString:@"/"options:NSBackwardsSearch];
return [pFile substringFromIndex:range.location + 1];
}
+(NSString*) GetFileName:(NSString*)pFile
{
NSRange range = [pFile rangeOfString:@"/"options:NSBackwardsSearch];
return [pFile substringFromIndex:range.location + 1];
}