function GetSystemDir: string;
begin
SetLength(Result, MAX_PATH);
GetSystemDirectory(PChar(Result), MAX_PATH);
Result := StrPas(PChar(Result))
end;
begin
SetLength(Result, MAX_PATH);
GetSystemDirectory(PChar(Result), MAX_PATH);
Result := StrPas(PChar(Result))
end;
Result := StrPas(PChar(Result))