Re: [twsocket] Still problems while sending SMTP

2007-01-18 Thread Francois Piette
> Regarding my last mail ('SMTP component not ready' exception), > I learnt that the problem doesn't occur if I put the whole > 'case RqType of: .. end;' into a try..except and simply ignore the exception. > But I'm not sure if this is the correct way to handle it. I haven't read the whole message

Re: [twsocket] Still problems while sending SMTP

2007-01-17 Thread Michael Kochendoerfer
>--- >Arno Garrels [TeamICS] >http://www.overbyte.be/eng/overbyte/teamics.html > > > > >>How can I prevent this situation from occuring? AFAIR, I shouldn't >>have a loop somewhere testing for the component state, so I need >>another mechanism to pr

Re: [twsocket] Still problems while sending SMTP

2007-01-17 Thread Arno Garrels
ks a lot ;) > > Michael > > >> -Original Message- >> From: [EMAIL PROTECTED] >> [mailto:[EMAIL PROTECTED] >> Behalf Of Arno Garrels >> Sent: Wednesday, January 17, 2007 10:55 AM >> To: ICS support mailing >> Subject: Re: [twsocket] Still

Re: [twsocket] Still problems while sending SMTP

2007-01-17 Thread Kochendoerfer, Michael
Of Kochendoerfer, Michael > Sent: Wednesday, January 17, 2007 3:29 PM > To: ICS support mailing > Subject: Re: [twsocket] Still problems while sending SMTP > > > Arno, > > now I implemented it all the way you suggested. I have a > message handler procedure, which decide

Re: [twsocket] Still problems while sending SMTP

2007-01-17 Thread Kochendoerfer, Michael
other things are fine now, thanks a lot ;) Michael > -Original Message- > From: [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED] > Behalf Of Arno Garrels > Sent: Wednesday, January 17, 2007 10:55 AM > To: ICS support mailing > Subject: Re: [twsocket] Still problems while sen

Re: [twsocket] Still problems while sending SMTP

2007-01-17 Thread Arno Garrels
Message- >> From: [EMAIL PROTECTED] >> [mailto:[EMAIL PROTECTED] >> Behalf Of Arno Garrels >> Sent: Wednesday, January 17, 2007 9:24 AM >> To: ICS support mailing >> Subject: Re: [twsocket] Still problems while sending SMTP >> >> >> In order t

Re: [twsocket] Still problems while sending SMTP

2007-01-17 Thread Kochendoerfer, Michael
> Sent: Wednesday, January 17, 2007 9:24 AM > To: ICS support mailing > Subject: Re: [twsocket] Still problems while sending SMTP > > > In order to reconnect safely you need to get out of your loop > after the session has been closed AND after OnRequestDone > has been triggered

Re: [twsocket] Still problems while sending SMTP

2007-01-17 Thread Arno Garrels
aborted or quit. Now I know I've to wait also >>> for not Connected. But what's the correct method to wait for >>> completion? Currently, I have a loop after calling Connect() >>> looking like this: >>> >>> while not FlagDone do begin

Re: [twsocket] Still problems while sending SMTP

2007-01-16 Thread david . lyon
;>> with Connect(), let the OnRequestDone do the background stuff and set >>> a flag if either aborted or quit. Now I know I've to wait also for >>> not Connected. But what's the correct method to wait for completion? >>> Currently, I have a loop a

Re: [twsocket] Still problems while sending SMTP

2007-01-16 Thread Michael Kochendoerfer
gt;> >>while not FlagDone do begin >> //Application.ProcessMessages; // Don't know whether or not to use >>the message pump here Sleep(50); >>end; >> >>Any thoughts? >> >>TIA, >>Michael >> >> >> >> >>&

Re: [twsocket] Still problems while sending SMTP

2007-01-16 Thread Angus Robertson - Magenta Systems Ltd
> my app is just single-threaded. The design doesn't require > multithreading because each mail is sent when the previous one has > been delivered. You still don't need threads to handle parallel delivery, just create an array of say 50 SMTP components, and queue mail to the next free one. A

Re: [twsocket] Still problems while sending SMTP

2007-01-16 Thread Michael Kochendoerfer
Wilfried, my app is just single-threaded. The design doesn't require multithreading because each mail is sent when the previous one has been delivered. But you gave me another idea for another part of my app ;) I think that all ideas I collected from Arno and all other contributors will help m

Re: [twsocket] Still problems while sending SMTP

2007-01-16 Thread Wilfried Mestdagh
Hello Michael, In addition to the reply of Arno: > Currently, I have a loop after calling Connect() looking like this: > while not FlagDone do begin > Sleep(50); > end; If this works then be aware that you call connect in another thread as the thread where the component is executing. Maybe it

Re: [twsocket] Still problems while sending SMTP

2007-01-16 Thread Arno Garrels
el > > >> -Original Message- >> From: [EMAIL PROTECTED] >> [mailto:[EMAIL PROTECTED] >> Behalf Of DZ-Jay >> Sent: Tuesday, January 16, 2007 10:57 AM >> To: ICS support mailing >> Subject: Re: [twsocket] Still problems while sending SMTP >&g

Re: [twsocket] Still problems while sending SMTP

2007-01-16 Thread Kochendoerfer, Michael
ED] > [mailto:[EMAIL PROTECTED] > Behalf Of DZ-Jay > Sent: Tuesday, January 16, 2007 10:57 AM > To: ICS support mailing > Subject: Re: [twsocket] Still problems while sending SMTP > > > > On Jan 16, 2007, at 02:49, Arno Garrels wrote: > > > When the response

Re: [twsocket] Still problems while sending SMTP

2007-01-16 Thread DZ-Jay
On Jan 16, 2007, at 02:49, Arno Garrels wrote: > When the response to the Quit command is received the connection > (may) still be alive. So watch both, whether Quit response has been > received as well as the SessionClose event. Call connect only > after the session has been closed. > Don't star

Re: [twsocket] Still problems while sending SMTP

2007-01-15 Thread Arno Garrels
Michael Kochendoerfer wrote: > calls .Connect. I can see in a log that OnRequestDone is fired > multiple times until it gets smtpQuit. When calling the next time, > I'll get the above exception. When the response to the Quit command is received the connection (may) still be alive. So watch both, w

Re: [twsocket] Still problems while sending SMTP

2007-01-15 Thread david . lyon
Quoting Michael Kochendoerfer <[EMAIL PROTECTED]>: > it's me again ... some of you directed me the right way sending SMTP > mails in async mode. I analyzed the MailSnd1 example and I built a > component based on TSmtpCli, which wraps some of my application specific > data. After setting all requi

[twsocket] Still problems while sending SMTP

2007-01-15 Thread Michael Kochendoerfer
Dear community, it's me again ... some of you directed me the right way sending SMTP mails in async mode. I analyzed the MailSnd1 example and I built a component based on TSmtpCli, which wraps some of my application specific data. After setting all required properties, I do a Connect and the c