 |
BorlandTalk.com Borland discussion newsgroups
|
| View previous topic :: View next topic |
| Author |
Message |
Tomas Guest
|
Posted: Wed Apr 11, 2007 8:11 am Post subject: Close connection before action complete (ISAPI) |
|
|
Hi
Could anyone explain how to close connection from ISAPI before action
actually finish?
My example code is below, as you see I send text response to browser and
then want to close connection and do not wait before
Sleep(100000); will be executed. Unfortunatelly connection is not closed and
I see loading proggress bar in IE until Sleep(100000);
executed.
procedure Twm.wmWebActionItem2Action(Sender: TObject; Request: TWebRequest;
Response: TWebResponse; var Handled: Boolean);
begin
response.SendResponse;
request.WriteHeaders(200, '200 OK', 'CONNECTION: CLOSE');
request.WriteString('Response to user');
response.SendResponse;
Sleep(100000); //This is just a tets, actually I am executing job-code
here
end;
Regards,
Tomas |
|
| Back to top |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|