Article View: borland.public.cppbuilder.internet.socket
Article #5211Re: How to make a TClientSocket to search a TServerSocket???
From: Remy Lebeau (TeamB)
Date: Fri, 01 Oct 2004 17:43
Date: Fri, 01 Oct 2004 17:43
27 lines
1777 bytes
1777 bytes
"Hans Galema" <dontusethis@dontusethis.nl> wrote in message
news:415d1c16$1@newsgroups.borland.com...
> Making ErrorCode zero suppresses the windowalert.
> But only if you do it right away:
Wrong. You can set ErrorCode to 0 at any time during the event handler. It
is not checked for 0 until after the event handler exits.
> ErrorCode=0; ShowMessage(mjwinsockerr(ErrorCode));
>
> or more readable:
>
> ErrorCode=0;
> ShowMessage(mjwinsockerr(ErrorCode));
That code is going to always pass 0 to mjwinsockerr(). If you want to set
ErrorCode to 0 before calling mjwinsockerr() then you need to use a second
variable:
int Err = ErrorCode;
ErrorCode=0;
ShowMessage(mjwinsockerr(Err));
Gambit
Technical Details
Message-ID:
<415d973b$1@newsgroups.borland.com>Path:
arc1-ca.pugleaf.net!g2news1.google.com!news2.google.com!news1.google.com!news.glorb.com!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mailReferences:
<41595ce4$1@newsgroups.borland.com> <41595eed$1@newsgroups.borland.com> <41596530$1@newsgroups.borland.com> <415d16cd@newsgroups.borland.com> <415d1c16$1@newsgroups.borland.com>Show Full Headers
Complete Article Headers
X-Google-Thread: 11508e,bd4b4d9b4b503463 X-Google-Attributes: gid11508e,public X-Google-Language: ENGLISH,ASCII-7-bit From: "Remy Lebeau \(TeamB\)" <no.spam@no.spam.com> Newsgroups: borland.public.cppbuilder.internet.socket References: <41595ce4$1@newsgroups.borland.com> <41595eed$1@newsgroups.borland.com> <41596530$1@newsgroups.borland.com> <415d16cd@newsgroups.borland.com> <415d1c16$1@newsgroups.borland.com> Subject: Re: How to make a TClientSocket to search a TServerSocket??? Date: Fri, 1 Oct 2004 10:43:33 -0700 Lines: 29 X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 6.00.2800.1409 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1409 NNTP-Posting-Host: 68.69.17.41 Message-ID: <415d973b$1@newsgroups.borland.com> X-Trace: newsgroups.borland.com 1096652603 68.69.17.41 (1 Oct 2004 10:43:23 -0700) Path: arc1-ca.pugleaf.net!g2news1.google.com!news2.google.com!news1.google.com!news.glorb.com!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newsgroups.borland.com!not-for-mail