Einzelnen Beitrag anzeigen

marabu

Registriert seit: 6. Apr 2005
10.109 Beiträge
 
#5

Re: Bitmap.LoadFromFile (internetfile)

  Alt 9. Jan 2007, 12:35
Hi,

you can use the following code, which is a variation from over there: klick

Delphi-Quellcode:
function DownloadBitmap(uri: String; bm: TBitmap): Boolean;
var
  s: TStream;
begin
  Result := False;
  s := TMemoryStream.Create;
  with TIdHTTP.Create(nil) do
  try
    Get(uri, s);
    bm.LoadFromStream(s);
    Result := True;
  finally
    Free;
    s.Free;
  end;
end;
Kind Regards
  Mit Zitat antworten Zitat