🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Thread View: borland.public.cppbuilder.database.multi-tier
4 messages
4 total messages Started by yc Fri, 02 Mar 2001 03:56
A Problem with TSocketConnection
#721
Author: yc
Date: Fri, 02 Mar 2001 03:56
16 lines
1379 bytes
I need to Create a MIDAS Applicaton using TSocketConnection.But when I
access a interface in the remote applicaton server,there is a error.the
interface has a parameter,it's type is 'IStringPtr *'.If I use
TDCOMConnection,there is no any errror.Why?
I access the interface as the example in the helpfile :

   IDispatch* disp = (IDispatch*)(DMClient->Connection->AppServer);
   IYoyoDisp TempInterface((IYoyo*)disp);
   if(TempInterface.InsertRecord(WideString(TableName),Value)!=S_OK)
     
Application->MessageBox("~{Or7~NqFwLa=;6)5%J'0\#!~}","~{7~NqFw75;X4mNs~}",MB_OK|MB_I
CONERROR);
     
If someone has the answer of this problem,please tell me and give me a
example of the answer.
Thanks.  
Re: A Problem with TSocketConnection
#728
Author: Onat TAKAK
Date: Mon, 05 Mar 2001 11:46
34 lines
1993 bytes
HELLO,
I Use The Connection as follow and it works fine.


IMyInterface *  anInterface;
    anInterface = (IMyInterface *) LPDISPATCH(MyConnection->AppServer);
IMyInterfaceDisp MyDisp(anInterface);

MyInterface.DoSomething();
....




yc <glyc@sina.com.cn> wrote in message news:01c0a2cc$8fc75f90$1400a8c0@dk...
> I need to Create a MIDAS Applicaton using TSocketConnection.But when I
> access a interface in the remote applicaton server,there is a error.the
> interface has a parameter,it's type is 'IStringPtr *'.If I use
> TDCOMConnection,there is no any errror.Why?
> I access the interface as the example in the helpfile :
>
>    IDispatch* disp = (IDispatch*)(DMClient->Connection->AppServer);
>    IYoyoDisp TempInterface((IYoyo*)disp);
>    if(TempInterface.InsertRecord(WideString(TableName),Value)!=S_OK)
>
>
Application->MessageBox("~{Or7~NqFwLa=;6)5%J'0\#!~}","~{7~NqFw75;X4mNs~}",MB
_OK|MB_I
> CONERROR);
>
> If someone has the answer of this problem,please tell me and give me a
> example of the answer.
> Thanks.
>
Re: A Problem with TSocketConnection
#730
Author: Onat TAKAK
Date: Mon, 05 Mar 2001 15:06
44 lines
2290 bytes
I am Sorry,
The Last line should be MyDisp.DoSomething();

Onat TAKAK <otakak@turk.net> wrote in message
news:97vts0$o494@bornews.inprise.com...
> HELLO,
> I Use The Connection as follow and it works fine.
>
>
> IMyInterface *  anInterface;
>     anInterface = (IMyInterface *) LPDISPATCH(MyConnection->AppServer);
> IMyInterfaceDisp MyDisp(anInterface);
>
> MyInterface.DoSomething();
> ....
>
>
>
>
> yc <glyc@sina.com.cn> wrote in message
news:01c0a2cc$8fc75f90$1400a8c0@dk...
> > I need to Create a MIDAS Applicaton using TSocketConnection.But when I
> > access a interface in the remote applicaton server,there is a error.the
> > interface has a parameter,it's type is 'IStringPtr *'.If I use
> > TDCOMConnection,there is no any errror.Why?
> > I access the interface as the example in the helpfile :
> >
> >    IDispatch* disp = (IDispatch*)(DMClient->Connection->AppServer);
> >    IYoyoDisp TempInterface((IYoyo*)disp);
> >    if(TempInterface.InsertRecord(WideString(TableName),Value)!=S_OK)
> >
> >
>
Application->MessageBox("~{Or7~NqFwLa=;6)5%J'0\#!~}","~{7~NqFw75;X4mNs~}",MB
> _OK|MB_I
> > CONERROR);
> >
> > If someone has the answer of this problem,please tell me and give me a
> > example of the answer.
> > Thanks.
> >
>
>
Re: A Problem with TSocketConnection
#731
Author: yc
Date: Tue, 06 Mar 2001 09:27
69 lines
2893 bytes
Thank you for your answer.
I using your method to try.When the paramters of method in the interface
are single type(as int ,BSTR..),there is no problem.But I use a IStringPtr*
paramter ,the problem  also is found .

Anothe Problem:
I open a example of C++ Builder 5 in folder :$(BCB)\Examples\Midas\Adhoc.It
use DCOM connect to server.I modify it using Socket to connect server.When
I comple and run it.There is a error when it is running:

	"Table :Missing TableName property".

I find the code in method of interface has no infect .the TableName and
DataBase property of Table in server have no changed.Why?

Thanks.

Onat TAKAK <otakak@turk.net> ~{1;P4Hk5=NDUB~} <9809lp$74c3@bornews.inprise.com>
~{VP~}...
> 
> I am Sorry,
> The Last line should be MyDisp.DoSomething();
> 
> Onat TAKAK <otakak@turk.net> wrote in message
> news:97vts0$o494@bornews.inprise.com...
> > HELLO,
> > I Use The Connection as follow and it works fine.
> >
> >
> > IMyInterface *  anInterface;
> >     anInterface = (IMyInterface *) LPDISPATCH(MyConnection->AppServer);
> > IMyInterfaceDisp MyDisp(anInterface);
> >
> > MyInterface.DoSomething();
> > ....
> >
> >
> >
> >
> > yc <glyc@sina.com.cn> wrote in message
> news:01c0a2cc$8fc75f90$1400a8c0@dk...
> > > I need to Create a MIDAS Applicaton using TSocketConnection.But when
I
> > > access a interface in the remote applicaton server,there is a
error.the
> > > interface has a parameter,it's type is 'IStringPtr *'.If I use
> > > TDCOMConnection,there is no any errror.Why?
> > > I access the interface as the example in the helpfile :
> > >
> > >    IDispatch* disp = (IDispatch*)(DMClient->Connection->AppServer);
> > >    IYoyoDisp TempInterface((IYoyo*)disp);
> > >    if(TempInterface.InsertRecord(WideString(TableName),Value)!=S_OK)
> > >
> > >
> >
> Application->MessageBox("~{Or7~NqFwLa=;6)5%J'0\#!~}","~{7~NqFw75;X4mNs~}",MB
> > _OK|MB_I
> > > CONERROR);
> > >
> > > If someone has the answer of this problem,please tell me and give me
a
> > > example of the answer.
> > > Thanks.
> > >
> >
> >
> 
> 
> 
Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads