// findfile.cpp : コンソール アプリケーションのエントリ ポイントを定義します。
//
#include "stdafx.h"
#include<iostream>
#include<string>
#include<io.h>
using namespace std;
void filesearch(string path,int layer)
{
long long lLastFileTime = 0;;
char cfile[256] = {0};
struct _finddata_t filefind;
string curr=path+"\\*.*";
int done=0,i,handle;
if((handle=_findfirst(curr.c_str(),&filefind))==-1)
return;
while(!(done=_findnext(handle,&filefind)))
{
if (filefind.time_create >= lLastFileTime)
{
memset(cfile, 0x00, 256);
lLastFileTime = filefind.time_create;
memcpy(cfile, filefind.name, strlen(filefind.name));
//
#include "stdafx.h"
#include<iostream>
#include<string>
#include<io.h>
using namespace std;
void filesearch(string path,int layer)
{
long long lLastFileTime = 0;;
char cfile[256] = {0};
struct _finddata_t filefind;
string curr=path+"\\*.*";
int done=0,i,handle;
if((handle=_findfirst(curr.c_str(),&filefind))==-1)
return;
while(!(done=_findnext(handle,&filefind)))
{
if (filefind.time_create >= lLastFileTime)
{
memset(cfile, 0x00, 256);
lLastFileTime = filefind.time_create;
memcpy(cfile, filefind.name, strlen(filefind.name));