星期五, 3月 13, 2009

取得磁碟剩餘空間


var
g_sTempDriver : integer;
DiskFreeSize : int64;
begin
g_sTempDriver := Ord(UpperCase(g_sTempPath)[1])-64; //UpperCase(g_sTempPath)[1]某個槽
DiskFreeSize := DiskFree(g_sTempDriver);

//DiskFreeSize div 1024 = bytes

沒有留言: