抱歉,今天的第二个问题很愚蠢。是否可以确定应用程序包中是否包含文件?我可以毫无问题地访问文件,即
NSString *pathAndFileName = [[NSBundle mainBundle] pathForResource:fileName ofType:@"plist"];
但不知道如何检查文件是否存在。
问候
戴夫
最佳答案
[[NSFileManager defaultManager] fileExistsAtPath:pathAndFileName];
关于iphone - 如何确定应用程序包中是否存在文件?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/2024302/