Re: IdHTTP.GET only works for me on second attempt?

Giganews Newsgroups
Subject: Re: IdHTTP.GET only works for me on second attempt?
Posted by:  Gloria Ho (gloria_dot_…@gmail.com)
Date: Tue, 26 Sep 2006

You need set Readtimeout.

---
Gloria Ho

"Jayc Salter" <ja…@registriesltd.com.au> wrote in message
news:3idvr3-chi.l…@oproxy.registriesltd.com.au...
> Hi
>
> I am using Delphi 2006 and indy.
>
> I use the following code to get the HTML from the website
> https://www.asxonline.com
>
> I find that the first time i click the button (running this code) i get
> a "Read Timeout" error on the idHTTP.GET but when i press it a second
> time it works correctly.
>
> procedure TForm2.Button1Click(Sender: TObject);
> begin
>          IdHTTP2.IOHandler := IdSSLIOHandlerSocketOpenSSL2;
>          IdSSLIOHandlerSocketOpenSSL2.Host      := 'www.asxonline.com';
>          IdSSLIOHandlerSocketOpenSSL2.Port      := 443;
>          IdHTTP2.HandleRedirects := True;
>
>          RichEdit1.Clear;
>          RichEdit1.Lines.Add(IdHTTP2.Get('https://www.asxonline.com'));
> end;
>
> All the other settings of the TidHttp and TIdSSLIOHandlerSocketOpenSSL
> are the defaults (i have experimented with most of them to see if they
help)
>
> has anyone got any ideas?
> Thanks for the help.

Replies

None

In response to

IdHTTP.GET only works for me on second attempt? posted by Jayc Salter on Thu, 24 Aug 2006