Einzelnen Beitrag anzeigen

MarkusMaier

Registriert seit: 10. Apr 2007
Ort: Traunreut
6 Beiträge
 
#14

Re: How to Use Indy 10 idHTTP : IOHandler value is not valid

  Alt 23. Okt 2008, 15:19
I was the one who restarted this thread after several years, i had the example code in one of my projects - found it via google and used it instead of using indy.

After a bit of research, i found out that this code works as well (and is less likely to produce errors):

Delphi-Quellcode:
var
  idHtp1:TIdHttp;
begin
  idHtp1:=TIdHTTP.Create(nil);
  Result := '';
  try
    try
      Result := idHtp1.Get(AUrl);
    finally
      FreeAndNil(idhtp1);
    end;
  except
    ;
  end;
end;
Thx to Angel4585
  Mit Zitat antworten Zitat