473,396 Members | 1,812 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

Remoting Passing objects

I'm creating 2 objects on a server from a remote client then calling a
function on one object passing the other as an argument to this. This
results in a Load lock exception. All objects are marshalbyref.

Does anyone know why this happens and what I can do about it?

here is the code outline

// shared interfaces C#.NET
interface A
{
B CreateB()
C CreateC()
}

interface B
{
void foo(C);
}

interface C
{
// some properties

}

// on the server C++.NET
class Aclass : public MarshalObjectByRef, public A
{
public:
virtual B CreateB() = A::CreateB { return (B)gcnew Bclass(); }
virtual C CreateC() = A::CreateC { return (C)gcnew Cclass(); }
};

class Bclass : public MarshalObjectByRef, public B
{
public:
virtual void foo(C obj) = B::foo { return; }
};

class Cclass : public MarshalObjectByRef, public c
{
// ...

};

// on the remote client C#.NET
B Bobj = A.CreateB();
C Cobj = A.CreateC();

// this works
Bobj.foo(null);

// this produces a load lock exception
Bobj.foo(Cobj);

Dec 19 '06 #1
0 1058

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

6
by: Catherine Jones | last post by:
Hi all, we need urgent help in a matter. We are trying to pass a COM object from the client to server and are facing some problems in the same. We've our client in C# as well as the Server...
0
by: Mike Grishaber | last post by:
Hello All, I am using an IHttpAsyncHandler class to intercept HTTP Requests and forward them to a system which processes the Request and returns the Result. I use .NET Remoting to connect the...
15
by: Ron L | last post by:
We are working on a distributed VB.Net application which will access a SQL database located on a known server. Each client will run on the user's local machine. To implement this, we are trying...
13
by: Ron L | last post by:
I am working on an application that is a front-end for a SQL database. While it is not an immediate requirement, the application will probably be required to be able to connect via the internet at...
1
by: Thomee Wright | last post by:
I'm having a problem with a pair of applications I'm developing. I have a server application which interacts with several instruments, and a client app which connects to the server and provides a...
3
by: Ryan H | last post by:
Hi, My data access layer for my VB.NET 1.1 application resides on a different server and is accessed via Remoting. Is there a way to configure my data access layer so that I can use...
0
mmfranke
by: mmfranke | last post by:
Hello. Hi. I'm writing a logging service that uses .NET remoting. The idea is that the service publishes an EventProcessor object that clients can access via .NET Remoting, passing it...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.