Article View: borland.public.cppbuilder.internet.socket
Article #1804WSADATA and BCB4 Windows app
From: DeKayA
Date: Mon, 30 Oct 2006 03:54
Date: Mon, 30 Oct 2006 03:54
29 lines
1519 bytes
1519 bytes
Hi
With many thanks to Michel Leunen
I was able to get my console ping working.
Now I am trying to set it up in a windows app.
I can't seem to even get off the ground though.
Where is WSAData defined.
In the console app I simply used
WSADATA wsa;
However i get the error
2451 Undefined symbol WSADATA
I included <windows.h>
I have looked at code submitted/corrected in the news group but I am
missing something.
__fastcall TForm1::TForm1(TComponent* Owner)
: TForm(Owner)
{
WSADATA wsa = {0};
int ret = WSAStartup(MAKEWORD(1, 0), &wsa);
WasInitialized = ( ret != 0 );
if( !WasInitialized ) MessageBox(NULL, ("Startup Error " +
AnsiString(ret)).c_str(),
"Error", MB_OK | MB_ICONERROR);
Technical Details
Message-ID:
<45467532.54908193@forums.borland.com>Path:
arc1-ca.pugleaf.net!g2news2.google.com!news1.google.com!newsfeed.gamma.ru!Gamma.RU!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mailShow Full Headers
Complete Article Headers
X-Google-Thread: 11508e,de49e8cdd75df900,start X-Google-Attributes: gid11508e,public X-Google-Language: ENGLISH,ASCII-7-bit From: DeKayA@bellsouth.net Newsgroups: borland.public.cppbuilder.internet.socket Subject: WSADATA and BCB4 Windows app Date: Mon, 30 Oct 2006 03:54:52 GMT Message-ID: <45467532.54908193@forums.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 1162180564 72.153.143.202 (29 Oct 2006 19:56:04 -0700) Lines: 33 Path: arc1-ca.pugleaf.net!g2news2.google.com!news1.google.com!newsfeed.gamma.ru!Gamma.RU!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail