首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > 移动开发 > 移动开发 >

列出程序索引中的指定文件夹的所有文件

2012-08-09 
列出程序目录中的指定文件夹的所有文件NSFileManager *m [NSFileManager defaultManager]NSArray *file

列出程序目录中的指定文件夹的所有文件

    NSFileManager *m = [NSFileManager defaultManager];    NSArray *fileList = [m directoryContentsAtPath:[[[[NSHomeDirectory() stringByAppendingPathComponent:@"Documents"]                                                      stringByAppendingPathComponent:@"163"]                                                      stringByAppendingPathComponent:@"songzi"] stringByAppendingPathComponent:@"pictures"]];    for (NSString *s in fileList){        NSLog(s);    }    

热点排行