?? no_callback.c
字號:
#include <time.h> /*Standard head file define here*/
#include <stdlib.h>
#include <stdio.h>
#include <string.h>
#include <tilcon/TRTAPI.h>
#include <DIRECT.H>
#include <time.h>
#include <io.h>
#include <windows.h>
#define Tree "File_System_Tree"
extern TRT_cid;
//GetVolumeInformation
int Load_File_System()
{
long p;/**//*查找文件的句柄*/
struct _finddata_t f;
int dir,file;
char Textbuffer[125]="";
char imagebuf[100]="";
char child_item[30]="";
p = _findfirst("*.*", &f);/**//*查找文件 且僅能查找當前工作目錄*/
if (p == -1)
{
TRT_SetValues(TRT_cid,"Message_Box",
TRT_ATT_TEXT,"以外錯誤 程序結束! ",NULL);
exit(-1);/**//*以外錯誤 程序結束*/
}
do
{
if (_A_SUBDIR == f.attrib) /*判斷是不是目錄*/
{
dir++; /*目錄個數 */
}
else
{
file++; /*文件個數 */
}
if (_A_SUBDIR != f.attrib) /*判斷是不是目錄*/
printf("%9lu\n",f.size); /*顯示文件大小*/
else
printf("\n"); /*目錄大小為0 dir命令不顯示*/
sprintf(Textbuffer,f.name); /*顯示文件名*/
sprintf(child_item,f.name);
sprintf(imagebuf,"%s\3%s\3%s\3%s\0",
"item0", child_item, Textbuffer, NULL);
TRT_SetValues(TRT_cid, Tree,
TRT_ATT_TREE_ITEMS_ADD_ID_IMAGE,imagebuf,
NULL);
}
while (!(_findnext(p,&f))); /*查找下一個 直到沒有文件為止*/
_findclose(p);
return 0;
}
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -