设为首页 加入收藏

TOP

C++读取特定路径下文件目录及文件名称(二)
2015-07-24 05:33:32 来源: 作者: 【 】 浏览:12
Tags:读取 特定 路径 文件 目录 名称
?
?8 ? ? if((hFile = _findfirst(p.assign(path).append("\\*").c_str(),&fileinfo)) != ?-1) ?
?9 ? ? { ?
10 ? ? ? ? do ?
11 ? ? ? ? { ? ?
12 ? ? ? ? ? ? if((fileinfo.attrib & ?_A_SUBDIR)) ?
13 ? ? ? ? ? ? { ?
14 ? ? ? ? ? ? ? ? if(strcmp(fileinfo.name,".") != 0 ?&& ?strcmp(fileinfo.name,"..") != 0) ?
15 ? ? ? ? ? ? ? ? {
16 ? ? ? ? ? ? ? ? ? ? //files.push_back(p.assign(path).append("\\").append(fileinfo.name) );
17 ? ? ? ? ? ? ? ? ? ? getFilesA( p.assign(path).append("\\").append(fileinfo.name), files );?
18 ? ? ? ? ? ? ? ? }
19 ? ? ? ? ? ? } ?
20 ? ? ? ? ? ? else ?
21 ? ? ? ? ? ? { ?
22 ? ? ? ? ? ? ? ? files.push_back(p.assign(path).append("\\").append(fileinfo.name) ); ?
23 ? ? ? ? ? ? } ?
24 ? ? ? ? }while(_findnext(hFile, &fileinfo) ?== 0); ?
25 ? ? ? ? _findclose(hFile);?
26 ? ? }?
27 }?
首页 上一页 1 2 下一页 尾页 2/2/2
】【打印繁体】【投稿】【收藏】 【推荐】【举报】【评论】 【关闭】 【返回顶部
分享到: 
上一篇Generate Parentheses 下一篇bzoj 2458: [BeiJing2011]最小三..

评论

帐  号: 密码: (新用户注册)
验 证 码:
表  情:
内  容: