Mirror

Download file via HTTP and load in memo (Views: 100)


Problem/Question/Abstract:

Download file via HTTP and load in memo

Answer:

This tip is based on you using NMHTTP component (FastNet).

var
  HTTP: TNMHTTP;
begin
  HTTP := TNMHTTP.Create(nil);
  HTTP.Get('http://www.somesite.com/news.htm');
  Memo1.Lines := HTTP.Body;
  HTTP.Free;
end;

<< Back to main page