CopyFile для Linux

Function CopyFile(Org, Dest:string):boolean;
 var Source, Target:TFileStream;
begin
 Result:=false;
 try
  try
  Source:=TFileStream.Create(Org, fmShareDenyNone or fmOpenRead);
  try
  Target:=TFileStream.Create(Dest, fmOpenWrite or fmCreate);
  Target.CopyFrom(Source,Source.Size);
  Result:=true;
  finally
  Target.Free;
  end;
  finally
  Source.Free;
  end;
 except
 end;
end;

Автор: Vit (www.delphist.com, www.drkb.ru, www.unihighlighter.com, www.nevzorov.org)

Отправить комментарий

Проверка
Антиспам проверка
Image CAPTCHA
...