Bin zwar nicht der Thread-Eröffner, aber Danke, damit funktioniert es:
Delphi-Quellcode:
function TForm1.resolveNetwork(str:string):string;
var
dwRetVal:word;
buffer:array[0..1024] of char;
dwBufferLength:cardinal;
s:string;
i:int;
begin
dwBufferLength:=1024;
s:='q:\test\';
dwRetVal:=WNetGetUniversalName(Pchar(s),UNIVERSAL_NAME_INFO_LEVEL,addr(buffer),dwBufferLength);
if (dwRetVal = NO_ERROR) then
begin
s:='';
for i:=4 to 1024 do
begin
if buffer[i]=#0 then
break;
s:=s+buffer[i];
end;
//showMessage(s);
end
result:=s;
end;