Skip to content

Remoting custom objects

Till Hoffmann

Asked Jul 27, 2007, 1:04 PM EDT2 answers
Share
LinkedInX
It is easy to remote an object if it is not yet created via RemotingConfiguration.RegisterWellKnownServiceType. How can I make a client use an object if it is already created on the server via the new operator because I don't want another one to be created when the client calls it.

2 Answers

Know the answer? Post it. Somebody with the same question will find it here.

  • Mike Gold
    0
    there are two types of remote objects (from what I remember),  a Singleton type, that is created once, and one that is created each time you call the method called SingleCall).  You want the Singleton type.
    0
  • 0
    I know that I have to use a singleton. I'll try to describe it a little differently: I already have an object created using the "new" operator on the server and I want that object to be remoted. However, if I call Activator.GetObject on the client side, it will create another singleton which is contradictory (two singletons) but it's true, unfortunately.
    0