| View previous topic :: View next topic |
| Author |
Message |
Gregor Guest
|
Posted: Sat Dec 20, 2003 3:12 pm Post subject: TidSmtpServer active Thread! |
|
|
Hi Volks !
How can I terminate (closed) one active Thread of manny Thread's from
TidStmpserver
TidSMTPServer.ThreadMgr.ActiveThreads-????????????
Sorry my English
Gregor
|
|
| Back to top |
|
 |
Remy Lebeau (TeamB) Guest
|
Posted: Mon Dec 22, 2003 12:36 am Post subject: Re: TidSmtpServer active Thread! |
|
|
"Gregor" <info (AT) ueding (DOT) de> wrote
| Quote: | TidSMTPServer.ThreadMgr.ActiveThreads-????????????
|
The ActiveThreads property is a TThreadList. You have to call its
LockList() method in order to gain access to a TList that contains the
actual thread pointers. The threads themselves will be of type
TIdSMTPServerThread. For example:
var
pList: TList;
begin
with IdSMTPServer1.ThreadMgr.ActiveThreads do
begin
pList := LockList
try
TIdSMTPServerThread(pList.Items[SomeIndex]).Connection.Disconnect;
finally
UnlockList;
end;
end;
end;
Gambit
|
|
| Back to top |
|
 |
|