Wednesday, February 6, 2013

Mendapatkan Ukuran File (C)


DWORD ukuran_file(char *namafile)
{
DWORD posisi=0;
DWORD akhir=0;
FILE *f;
f=fopen(namafile,"rb");
posisi=ftell(f);
fseek(f,0,SEEK_END);
akhir=ftell(f);
fseek(f,posisi,SEEK_SET);
fclose(f);
return akhir;
}
view raw ukuranfile.c hosted with ❤ by GitHub

No comments:

Post a Comment