Also hab ich das richtig verstanden, das es so gehen müsste?
Delphi-Quellcode:
function GetWinVersion: string;
begin
result:='Unbekannte Version';
case Win32Platform of
1:// 9x-Reihe
If Win32MajorVersion=4 Then Begin
Case Win32MinorVersion of
0: result:='Windows 95';
10: result:='Windows 98';
90: result:='Windows Me';
end;
end;
/////////////////////////////////////////////
If Win32MajorVersion=6 Then Begin
Case Win32MinorVersion of
0: result:='Windows Vista';
end;
2: // NT-Reihe
Case Win32MajorVersion of
3:IF Win32MinorVersion=51 then
result:='Windows NT 3.51';
4:If Win32MinorVersion=0 then
result:='Windows NT 4';
5:Case Win32MinorVersion of
0: result:='Windows 2000';
1: result:='Windows XP';
2: result:='Windows .NET Server';
3: result:='Windows Vista';
end;
End;
end;
//Win32CSDVersion enthält Informationen zu Servicepacks
if Win32CSDVersion<>'' then
result:=result+' '+Win32CSDVersion;
end;