🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.cppbuilder.database.multi-tier
Article #637

Re: Calling Sever Interfaces

#637
From: John Graham
Date: Fri, 25 May 2001 14:55
63 lines
3088 bytes
Gents,

This is an error in the help screen where this example is displayed - there
is no ";" at the end of the line.  I have tried this code to create a
temporary interface with no success.

My nTier client app. uses the Bind() method of the TAutoDriver class this
way:

  SMSrvrDisp = new ISysManSrvrRDMDisp();

  SMSrvrDisp->Bind(WideString(SysManScktConnect->ServerName));

  if ( !SMSrvrDisp->IsBound() )
   {
     Application->MessageBox("Can't Bind Dispatch Interface - Aborting!",
"Rats!", MB_ICONEXCLAMATION);

   Application->Terminate();
  }

This works fine when I run the client and app. server under Windows 2000 on
the same machine.  However, when I try to
run the client app. on an NT machine I get the "Can't Bind Dispatch
Interface - Aborting!" error.

If I comment the error trap out, the client application runs fine on the NT
machine and the application server runs ok on the 2000 machine as long as I
don't try to call any app. server methods.  This leads me to believe
something is wrong with the way I'm trying to bind the interface.

Conversely, if I use:

  SMSrvrDisp->Bind(LPDISPATCH(SysManScktConnect->AppServer));

It errors when both client and server are running on the 2000 machine as
well.  The above line is what I use for the same application developed with
BCB4 on an NT machine.

The version of this app developed with BCB4 under NT allows the client to
run under any Windows OS ( 95 and above ) with the app. server running on
any of our NT servers.

What am I missing?

Regards,
John

Mark Cashman wrote:

> Hi, Alejandro!
>
> You are missing a ";" on the first line you show, which is causing your
> syntax error message.
>
> ------
> Mark Cashman (TeamB - C++ Builder), creator of The Temporal Doorway at
> http://www.temporaldoorway.com
> - Original digital art, writing, music and more -
> C++ Builder / JBuilder Tips and The C++ Builder Programmer's Webring
> (Join us!)
> http://www.temporaldoorway.com/programming/index.htm
> ------
Technical Details
Message-ID: <3B0E7269.7ADAB1D8@salts.navy.mil>
Path: arc1-ca.pugleaf.net!archiver1.google.com!newsfeed.google.com!sn-xit-02!supernews.com!bignews.mediaways.net!news.uni-paderborn.de!newsfeed01.sul.t-online.de!newsfeed00.sul.t-online.de!t-online.de!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!newsfeed.wirehub.nl!PeerFeed.KWeb.on.ca!dnews
References: <3b043fc4_2@dnews> <3B09C3DD.F61D034B@temporaldoorway.com>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: fcd2b,3539babba80a45b1
X-Google-Attributes: gidfcd2b,public
X-Google-ArrivalTime: 2001-05-25 07:57:37 PST
Message-ID: <3B0E7269.7ADAB1D8@salts.navy.mil>
Date: Fri, 25 May 2001 10:55:37 -0400
From: John Graham <jgraham@salts.navy.mil>
Organization: SALTS Central
X-Mailer: Mozilla 4.76 [en] (WinNT; U)
X-Accept-Language: en
MIME-Version: 1.0
Newsgroups: borland.public.cppbuilder.database.multi-tier
Subject: Re: Calling Sever Interfaces
References: <3b043fc4_2@dnews> <3B09C3DD.F61D034B@temporaldoorway.com>
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
NNTP-Posting-Host: 163.12.6.113
X-Trace: dnews 990802203 163.12.6.113 (25 May 2001 07:50:03 -0700)
Lines: 64
Path: arc1-ca.pugleaf.net!archiver1.google.com!newsfeed.google.com!sn-xit-02!supernews.com!bignews.mediaways.net!news.uni-paderborn.de!newsfeed01.sul.t-online.de!newsfeed00.sul.t-online.de!t-online.de!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!newsfeed.wirehub.nl!PeerFeed.KWeb.on.ca!dnews