Althoug I don't know for what reason you might need this, here's my answer
Zitat von
cdkiller:
fs2.ReadBuffer(Buffer2^,Sizeof(Buffer2^));
where is the error or can you fix it ?
What do you expect "Sizeof(Buffer2^)" to be? you should use "FS2.Size" instead of it... I didn't check if this works cause I'd use the function "CopyFrom":
Delphi-Quellcode:
var
fs,fs2 : TFileStream;
begin
if OpenDialog1.Execute then
try
fs := TFileStream.Create(OpenDialog1.FileName, fmOpenReadWrite);
fs2 := TFilestream.Create('myDLL.dll', fmOpenRead);
fs.Seek (fs.Size,soFromBeginning);
fs2.Seek(0, soFromBeginning);
fs.CopyFrom(fs2,fs2.Size);
finally
fs.Free;
fs2.Free;
end;
end;
(By the way: there were a few 'errors' in your code
, e.g. you don't need to read sth. from FS.)
Greetz
Stephan
Stephan B.
Wer andern eine Grube gräbt ist Bauarbeiter!
Wer im Glashaus sitzt, sollte sich lieber im Dunkeln ausziehen!
Außerdem dieser Satz kein Verb...