Re: [twsocket] Multiple declaration for 'sockaddr'

2011-12-17 Thread Ole Braad-Sørensen

I know. This don't chane anything.

On Sat, 17 Dec 2011 10:37:26 +0800, you wrote:

Hi,

Downloading from overbyte is always the best solution. You might want to 
download the latest version form ics website. 


On Dec 17, 2011, at 2:06, Ole Braad-Sørensen o...@soholm.com wrote:

 
 Hi!
 
 Just installed BCB XE and with the DVD was the Overbyte package.
 I have installed it and trying to use it, but get the error:
 
 Multiple declaration for 'sockaddr'
 
 I know that it is something to do with the winsock file.
 
 I have tried to move around with the includes, but no luck.
 
 I have also for many years ago read something about a fix for this error.
 Something about uncommenting something somewhere, but can't remember what.
 
 Anyone hwo have a fix for this...?
 
 --
 Regards:
 Ole Braad-Sorensen
 www.fotogator.dk
 --
 To unsubscribe or change your settings for TWSocket mailing list
 please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
 Visit our website at http://www.overbyte.be
--
Med venlig hilsen
Ole Braad-Sørensen
www.soholm.com
(Danmarks kedeligste hjemmeside)
--
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be

[twsocket] Multiple declaration for 'sockaddr'

2011-12-16 Thread Ole Braad-Sørensen

Hi!

Just installed BCB XE and with the DVD was the Overbyte package.
I have installed it and trying to use it, but get the error:

Multiple declaration for 'sockaddr'

I know that it is something to do with the winsock file.

I have tried to move around with the includes, but no luck.

I have also for many years ago read something about a fix for this error.
Something about uncommenting something somewhere, but can't remember what.

Anyone hwo have a fix for this...?

--
Regards:
Ole Braad-Sorensen
www.fotogator.dk
--
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be


Re: [twsocket] Errorcode 23396 when trying to use TSmtpCli in C++

2009-05-22 Thread Ole Braad-Sørensen

Sorry for late reply. Have been away..!

On Tue, 19 May 2009 08:31:54 +0200, you wrote:

How did you install it exactely? Did you install for both personalities
from the Delphi personality building the Delphi package with linker 
option Generate All C++Builder Files, or did you install the C++Builder
install group in the C++Builder personality?

I installed as described in the file: Readme7.txt.

With both personalities loaded, I selected the file CB2009Install.groupproj
Selected the ...run.bpl and made a build.
Then selected the ...design.bpl and made an Install.

No errors was shown and the packages was apparently installed correct.

Now, I have just tried what you mention above. In the options I selected the
Generate All C++Builder Files option and made a build on the ...run.bpl.

and got the error: 
[ILINK32 Error] Fatal: Unable to open file 'OVERBYTEICSWINSOCK.OBJ'
and of course, when trying to build the ...design.bpl I get:
[ILINK32 Error] Fatal: Unable to open file 'OVERBYTEICSCB2009RUN.BPI'

Two more errors for my collection :-(

Back to the Generate C++ .objs, headers, namespaces, export option, the ICS
installs without errors, but my little simple project fails..!

Thanks again for taking your time for helping me. If it works for you, it should
also be possible to get it working here too. I am sending the project to you
PM  :-))

Regards:
Ole Braad-Sorensen
www.importshop.dk
-- 
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be


Re: [twsocket] Errorcode 23396 when trying to use TSmtpCli in C++

2009-05-19 Thread Ole Braad-Sørensen
On Mon, 18 May 2009 12:00:01 +, you wrote:

All I can say is that it is working nicely with BCB in my little test
application. The problem must be IMO something on your side. 
You can sent me your project if you like by PM so I can test it with my
clean ICS installation. If the mail server is public please send me
its address as well.   

Thanks for taking your time to solve this problem.!

Just made an experiment: Installed BCB2009 on my laptop. No BCB has ever been
there before and I take it as a clean machine. Installed ICS on the system and
made a new version of my email demo. Guess what happened: Got the same error
there :-(

Just before I give up and go back to the working BCB6 in stead.

I would appreciate if you would try my little demo email on your system for
testing. What do you mean by sending it by PM...?

The mail server is om my local network and cannot be reached from outside world.

Regards:
Ole Braad-Sorensen
www.importshop.dk
-- 
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be


[twsocket] Errorcode 23396 when trying to use TSmtpCli in C++

2009-05-17 Thread Ole Braad-Sørensen
On Thu, 14 May 2009 10:31:53 +, you wrote:

 
 Possibly you need breaks? :-)
 
 switch(RqType)
  {
   case smtpConnect:  SMTP-Helo(); break;
   case smtpHelo: SMTP-MailFrom(); break;
   case smtpEhlo: SMTP-Auth(); break;
   case smtpAuth: SMTP-MailFrom(); break;
   case smtpMailFrom: SMTP-RcptTo(); break;
   case smtpRcptTo:   SMTP-Data(); break;
   case smtpData: SMTP-Quit(); break;
  }
 
 No. Tried this too. 

Really?

Yes, really :-)


So please try again, it works fine with the breaks!  
 

Maybe I did not explain myself thorough enouch, sorry!

The breaks has no effect in this case, as the error comes long before the breaks
will be at any use. Much code hes been made and you have not seen it all :-)

Made another try on another small project with the same result. See here:

First the MailSendButton:

void __fastcall TForm2::ButtonClick(TObject *Sender)
{
SMTP-Host   = EditHost-Text;
SMTP-Port   = EditPort-Text;
SMTP-SignOn = EditSignOn-Text;
SMTP-FromName   = EditFromName-Text;
SMTP-HdrFrom= EditFromName-Text;
SMTP-HdrTo  = EditHdrTo-Text;
SMTP-HdrCc  = EditHdrCc-Text;
SMTP-HdrSubject = EditHdrSubject-Text;
SMTP-Username   = EditUserName-Text;
SMTP-Password   = EditPassword-Text;
SMTP-RcptName-Clear();
SMTP-RcptNameAdd(EditHdrTo-Text, EditHdrCc-Text, EditHdrBcc-Text);
Display(Connecting to mailserver);
SMTP-Connect();
}

And now the OnRequestdone:  (with breaks)  :-)

void __fastcall TForm2::SMTPRequestDone(TObject *Sender, TSmtpRequest RqType,
WORD ErrorCode)

{

 // When arriving to here from Connect,
 // the RqType is = 0 and the ErrorCode is = 23396  - :-(
 // What is ErrorCode 23396 ?  (Guess it is not known)

 if (ErrorCode  0  ErrorCode  1) {
  Display(RequestDone Rq= + IntToStr(RqType) +  Error= +
SMTP-ErrorMessage);
 } else {
  Display(RequestDone Rq= + IntToStr(RqType) +  Error= +
IntToStr(ErrorCode));
 }

 if (ErrorCode == 0) {
  switch(RqType)
   {
case smtpConnect:   SMTP-Helo();   break;
case smtpHelo:  SMTP-MailFrom();   break;
case smtpEhlo:  SMTP-Auth();   break;
case smtpAuth:  SMTP-MailFrom();   break;
case smtpMailFrom:  SMTP-RcptTo(); break;
case smtpRcptTo:SMTP-Data();   break;
case smtpData:  SMTP-Quit();   break;
case smtpQuit:  break;
   }
 }
}

As you see in the comments above, the switch is never reached :-(

The above program is a copy of the MailSnd example, which is in Delphi and works
great here. But in my translation to C++ it do not work. I may have missed
something or the SMTP thing don't work at all in C++.

Any suggestions...?

Regards:
Ole Braad-Sorensen
www.importshop.dk
-- 
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be


[twsocket] Errorcode 23396 when trying to use TSmtpCli in C++

2009-05-17 Thread Ole Braad-Sørensen
On Sun, 17 May 2009 11:32:30 +, you wrote:

I saw similar problem with thttpcli and it went away when I cleaned
and rebuilt the ICS package.

Isn't life strange. I just updated using SVN, cleaned, rebuilt and installed the
ICS package.

Would you believe it. Now I don't get the errorcode 23396 anymore...!
It has changed to ErrorCode = 61582.

Sad enough, this don't help much. Maybe another compile will show something
different. At last I could get lucky and getting the whole thing working. But
maybe just after some years. Better waiting for the next Indy update... :-(

Regards:
Ole Braad-Sorensen
www.importshop.dk
-- 
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be


[twsocket] Errorcode 23396 when trying to use TSmtpCli in C++

2009-05-17 Thread Ole Braad-Sørensen
On Sun, 17 May 2009 11:32:30 +, you wrote:

Please show us what is returned (if anything) when you telnet the mail
server from the same machine from where you tried the C++ EXE.
Command prompt: telnet hostname 25.

The server responds with:
220 apollon.soholm.com ESMTP Sendmail 8.13.2 (and so on)

When I type: ehlo soholm.com it responds with:
250-apollon.soholm.com Hello [192.168.1.1], pleased to meet you
250-ENHANCEDSTATUSCODES
250-PIPELINING
250-8BITMIME
250-SIZE
250-DSN
250-ETRN
250-DELIVERY
250-HELP

When I type: helo soholm.com it responds with:
250-apollon.soholm.com Hello [192.168.1.1], pleased to meet you

The answers do not match the errors I get from my program, no? :-)

Using telnet I can send a message. But a but clumsy...!

Regards:
Ole Braad-Sorensen
www.importshop.dk
-- 
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be


Re: [twsocket] TWSocket Digest, Vol 321, Issue 1

2009-05-14 Thread Ole Braad-Sørensen
On Mon, 11 May 2009 12:00:01 +, you wrote:

You do not check for ErrCode = 0 in OnRequestDone.
Put a break point before or at the switch statement and single-step
thru the code. That will show you what's wrong.

Dont' think that the code I showed was til only code I have tried.

I have tried nearly everything. Including checking for errorcode 0.

The hint with a brek-point is also tried. Omly showing that the problem comes in
the second line in the Case block. But why, I cant figure out.

From your answer it sounds as you know it, so it would be a great help to put a
finger on it in staead of just pointing. 

The mailsnd example works great, but it is in Delphi. Wonder if this works in
C++ at all? Has anyone tried it in C++, I would be grateful to know and even
more if you could show me what you did.

Regards:
Ole Braad-Sorensen
www.importshop.dk
-- 
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be


Re: [twsocket] TWSocket Digest, Vol 321, Issue 4

2009-05-14 Thread Ole Braad-Sørensen
On Tue, 12 May 2009 12:00:01 +, you wrote:

Possibly you need breaks? :-)

switch(RqType)
  {
   case smtpConnect:  SMTP-Helo(); break;
   case smtpHelo: SMTP-MailFrom(); break;
   casesmtpEhlo: SMTP-Auth(); break;
   casesmtpAuth: SMTP-MailFrom(); break;
   casesmtpMailFrom: SMTP-RcptTo(); break;
   casesmtpRcptTo:   SMTP-Data(); break;
   casesmtpData: SMTP-Quit(); break;
  }

No. Tried this too. The breaks has no effect in this switch
( No default value )

Regards:
Ole Braad-Sorensen
www.importshop.dk
-- 
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be


[twsocket] vFAQ - SMTPCli - Component not ready

2009-05-11 Thread Ole Braad-Sørensen

I know this is a vFAQ, but please read anyway :-)

Using Codegear C++2009, I have tried to use the example Mailsnd.

My code:

 SMTP-Host = Data-TAoplysning-FieldByName(Mailserver)-AsString;
 SMTP-Port = Data-TAoplysning-FieldByName(Port)-AsInteger;
 SMTP-SignOn = Data-TAoplysning-FieldByName(Email1)-AsString;
 SMTP-FromName = Data-TAoplysning-FieldByName(Firma)-AsString;
 SMTP-HdrFrom = Data-TAoplysning-FieldByName(Email1)-AsString;
 SMTP-HdrTo = Edit1-Text;
 SMTP-HdrSubject = Edit3-Text;
 SMTP-AuthType = smtpAuthNone;
 SMTP-Username = Data-TAoplysning-FieldByName(Brugernavn)-AsString;
 SMTP-Password = Data-TAoplysning-FieldByName(MailKodeord)-AsString;
 SMTP-HdrPriority = smtpPriorityNone;
 SMTP-ConfirmReceipt = false;
 SMTP-RcptName-Clear();
 SMTP-RcptNameAdd(Edit2-Text,Edit3-Text,Edit4-Text);
 SMTP-MailMessage =  Memo1-Lines;
 SMTP-Connect();

And the code for RequestDone:

 switch(RqType)
  {
   case smtpConnect:  SMTP-Helo();
   case smtpHelo: SMTP-MailFrom();
   case smtpEhlo: SMTP-Auth();
   case smtpAuth: SMTP-MailFrom();
   case smtpMailFrom: SMTP-RcptTo();
   case smtpRcptTo:   SMTP-Data();
   case smtpData: SMTP-Quit();
  }

When using above code I get the famous error Component not ready
and the mail-server log show: 

May 11 07:40:24 apollon sendmail[19691]: n4B5eNZs019691: [192.168.1.1] did not
issue MAIL/EXPN/VRFY/ETRN during connection to MTA

I know I am missing something, but can't figure out what...

Any ideas of what I should look for...?

Regards:
Ole Braad-Sorensen
www.foldrenser.dk
-- 
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be