Zitat von
fajac:
Ungetestet
Genau. Denn der Code schreibt den Zeiger statt die Daten in den Stream.
Delphi-Quellcode:
var
FFileName: PWideChar;
FFileNameLength: Word;
FFileString: WideString;
...
FFileString := WideString(FFileName);
FFileNameLength := Length(FFileString);
...
if FFileNameLength > 0 then { <== }
Write(FFileString{ ==> }[1]{ <== }, FFileNameLength * SizeOf(WideChar));
[/quote]