🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.cppbuilder.internet.socket
Article #1813

Re: WSADATA and BCB4 Windows app

#1813
From: DeKayA
Date: Mon, 30 Oct 2006 21:01
40 lines
2300 bytes
>> Why was it not required in the console app?
>
>You probably included something else that then implicitally included
>winsock.h for you.

Well I don't know where, since these 
#include <windows.h>
#include <stdio.h> 
are the only two includes in the original functioning console program.

Which is why I previously wondered why my console program worked
without winsock.h explicitly included. 

I had previously erroneously thought (prior to your redirection)
windows.h did it.


>If you need to destroy something yourself, then you have to
>add a destructor to your code as needed.

>> When I add this is says it has already been defined.

>You probably did not define the destructor in your header file:
>
>    public:
>        __fastcall TForm1(TComponent *Owner);
>        __fastcall ~TForm1(); // <-- add this manually


At first I wondered why I would have to define the destructor in my
header file, if it was complaining that it had already been defined.

But you are right.   I added it to the header and it quit complaining
that it had already been defined.   You can see my confusion with the
error message  "ALREADY DEFINED" !   So I guess by putting one in the
header you effectively override the one the compiler would have used.


So off to further learning
Thanks
Technical Details
Message-ID: <45476653.2782591@forums.borland.com>
Path: arc1-ca.pugleaf.net!g2news2.google.com!news2.google.com!news3.google.com!border1.nntp.dca.giganews.com!nntp.giganews.com!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail
References: <45467532.54908193@forums.borland.com> <45457d21$1@newsgroups.borland.com> <4546ff52.90268529@forums.borland.com> <45464085$1@newsgroups.borland.com>

Show Full Headers
Complete Article Headers
X-Google-Thread: 11508e,de49e8cdd75df900
X-Google-Attributes: gid11508e,public
X-Google-Language: ENGLISH,ASCII-7-bit
From: DeKayA@bellsouth.net
Newsgroups: borland.public.cppbuilder.internet.socket
Subject: Re: WSADATA and BCB4 Windows app
Date: Mon, 30 Oct 2006 21:01:15 GMT
Message-ID: <45476653.2782591@forums.borland.com>
References: <45467532.54908193@forums.borland.com> <45457d21$1@newsgroups.borland.com> <4546ff52.90268529@forums.borland.com> <45464085$1@newsgroups.borland.com>
X-Newsreader: Forte Agent 1.5/32.452
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
NNTP-Posting-Host: 72.153.143.202
X-Trace: newsgroups.borland.com 1162242147 72.153.143.202 (30 Oct 2006 13:02:27 -0700)
Lines: 45
Path: arc1-ca.pugleaf.net!g2news2.google.com!news2.google.com!news3.google.com!border1.nntp.dca.giganews.com!nntp.giganews.com!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail