🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

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

Re: AppServer property

#1451
From: Steve Pietrykoski
Date: Fri, 10 Sep 1999 00:00
33 lines
1453 bytes
Jean,

Here is a macro I've written:

#define APPSERVER_INTERFACE( CONNECTION, SERVERNAME, VAR ) \
  IDispatch * VAR##Disp = (IDispatch *)(CONNECTION->AppServer); \
  I##SERVERNAME * VAR##Intf = reinterpret_cast<I##SERVERNAME
*>(VAR##Disp); \
  I##SERVERNAME##Disp VAR( VAR##Intf );

It declares a interface variable that you can use; here is an example:

  APPSERVER_INTERFACE( SocketConnection1, MaestroMain, Disp );

where MaestroMain is the name of the remote module and Disp is the
variable that you are declaring.  You can then use
Disp.YourInterfaceFunction().

Steve Pietrykoski


Jean Ferreira wrote:
> 
> Hi guys,
> 
> I work with Delphi and sometimes I need to use C++Builder 4 SP1.
> 
> I need of some example of how cast the property AppServer to my interface.
> All examples that have in C++Builder does't work.
> 
> Thanks in advance,
> 
> Jean
Technical Details
Message-ID: <37D92EBF.E54541BE@artisansoftware.com>
Path: arc1-ca.pugleaf.net!unknown!not-for-mail
References: <7rb04e$rb98@forums.borland.com>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: fcd2b,cc2462d310d5f4a
X-Google-Attributes: gidfcd2b,public
From: Steve Pietrykoski <steve@artisansoftware.com>
Subject: Re: AppServer property
Date: 1999/09/10
Message-ID: <37D92EBF.E54541BE@artisansoftware.com>
X-Deja-AN: 523439177
Content-Transfer-Encoding: 7bit
References: <7rb04e$rb98@forums.borland.com>
X-Accept-Language: en
Content-Type: text/plain; charset=us-ascii
Organization: Artisan Software, LLC
Mime-Version: 1.0
Newsgroups: borland.public.cppbuilder.database.multi-tier