NSArray *documentPath = NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask, YES);
NSString *currDircetory = [documentPath objectAtIndex:0];
NSArray *filePathsArray = [[NSFileManager defaultManager] subpathsOfDirectoryAtPath:currDircetory error:nil];
for (NSString *s in filePathsArray){
NSLog(@"file %@", s);
}
現在我使用上面的代碼從文檔目錄中獲取文件列表,現在我想知道如何獲取文檔目錄中文件的修改時間。在iphone中獲取文檔目錄文件的日期修改時間
感謝,
維賈雅恩
謝謝ABI,它的工作原理 – user1844142
@ user1844142歡迎!請你接受答案:P –