Re: [twsocket] HttpCli.Abort

2006-03-14 Thread Francois Piette
> Francois, what is the best way to handle this one? I can set a 'flag' within > the LocationChange handler and use it to Abort the client at a later moment > (or discard its content etc). I've also seen people talk about using > PostMessage but I'm not sure how to do that. How would I create a mes

Re: [twsocket] HttpCli.Abort

2006-03-13 Thread Merijn Terheggen
Okay, I definitely reproduced the behavior you're describing. I used some old code that I once used for some spidering experiments. It iteratively parses each page it retrieves and then follows each link etc. No OnRequestDone event in case of certain Aborts. The example I found: Aborting from with

Re: [twsocket] HttpCli.Abort

2006-03-13 Thread Merijn Terheggen
Are you sure? I experimented with ICS.HttpCli and used the OnRequestDone event to set flags for further download decisions. I use a timeout check and abort clients that take too long. However, I experienced certain clients never getting to OnRequestDone. That could very well be in aborted cases. H

Re: [twsocket] HttpCli.Abort

2006-03-05 Thread Francois PIETTE
> Can you call HttpCli.Abort and immediately start a new request wihout > problems ? It is better to be out of any of the component event to abort. If you need to abort from a condition detected in an event, use PostMessage to defer the abort until out of the event. You can start a new reques

Re: [twsocket] HttpCli.Abort

2006-03-05 Thread Wilfried Mestdagh
Hello Paul, No you start new request in OnRequestDone checkin the HttpState must be Ready. --- Rgds, Wilfried [TeamICS] http://www.overbyte.be/eng/overbyte/teamics.html http://www.mestdagh.biz Sunday, March 5, 2006, 18:31, Paul wrote: > Can you call HttpCli.Abort and immediately start a new re

Re: [twsocket] HttpCli.Abort

2006-02-19 Thread Tibor Csonka
As far as I know WaitForSingle(/Multiple)Object will block your thread, and if you are working with a single thread that means it will block you main thread indefinitely because once blocked you cannot set events or semnalize semaphores etc.. There are some cases in which OnRequestDone is not c

Re: [twsocket] HttpCli.Abort

2006-02-19 Thread Francois PIETTE
> Does the Abort method works immediately or is it better to destroy and > recreate the component ? No need to destroy the component. But before doing something else, wait to receive the OnrequestDone which will be triggered by Abort (If memory serve me well). >> It is probably a good idea to

Re: [twsocket] HttpCli.Abort

2006-02-19 Thread Paul
> Which error code do you get ? Always hard to tell : I get the information from someone on the planet :-( I've tried to simulate it here, but no luck so far. Does the Abort method works immediately or is it better to destroy and recreate the component ? > It is probably a good idea to wait a

Re: [twsocket] HttpCli.Abort

2006-02-19 Thread Francois PIETTE
>I encounter some problems with the HttpCli when a virus scanner is updating >itself. > I think the virus scanner is blocking the internet connection, which > results in errors in the HttpCli.Requestdone event. Which error code do you get ? > It is save to call the Abort method and restart the