Re: Remote client is using local object instead of remote object
From: Ken Kolda (ken.kolda_at_elliemae-nospamplease.com)
Date: 11/30/04
- Next message: Ken Kolda: "Re: Remoting Performance over a WAN with HTTP"
- Previous message: webbarbarian: "Re: Remote client is using local object instead of remote object"
- In reply to: webbarbarian: "Re: Remote client is using local object instead of remote object"
- Next in thread: Magne Ryholt: "Re: Remote client is using local object instead of remote object"
- Messages sorted by: [ date ] [ thread ]
Date: Tue, 30 Nov 2004 15:11:43 -0800
The System.Runtime.Remoting.Channels.Tcp and
System.Runtime.Remoting.Channels.Http should be available with .NET 1.0 as
far as I know. However, you need to add a reference to the
System.Runtime.Remoting assembly to your project in order to use the classes
in these namespaces.
Ken
"webbarbarian" <webbarbarian@discussions.microsoft.com> wrote in message
news:C7BBA4A7-B200-4ACB-9621-582EB9F63A68@microsoft.com...
> Ken,
>
> Thank you very much for your help. Indeed the Assert() failed.
>
> Am I correct in assuming that the Channels.Http and Channels.Tcp
namespaces
> require the 1.1 framework? If so, then I will be unable to continue with
that
> until I install VS.NET 2003 becuase I'm still working with 1.0 framework.
> Thankfully, it is suppose to be installed in the next day or so.
>
> Thanks for your help!
>
> - b -
>
> "Ken Kolda" wrote:
>
> > As you mentioned, you must be loading the object locally instead of
> > retrieving it from the server. This is a common problem which
unfortunately
> > is not always obvious if you use the <wellknown> config file entry (or
use
> > RegisterWellKnownClientType() in your code). Almost certainly, your
problem
> > is one of the following:
> >
> > 1) Your client's config file is formatted incorrectly. Make sure you've
> > copied what's in the article exactly.
> > 2) You're not calling RemotingConfiguration.Configure() in your client
app
> > prior to the code that instantiates the remote object.
> >
> > A couple of things you can do to help debug:
> >
> > 1) After calling RemotingConfiguration.Configure(), call
> > RemotingConfiguration.GetRegisteredWellKnownClientType(). It should
return
> > an array containing a WellKnownClientTypeEntry for your remote object.
If
> > not, your config file is not being read or is malformatted.
> >
> > 2) Add a line after creating your remote object instance:
> >
> > MyRemoteObject robj = new MyRemoteObject();
> >
System.Diagnostics.Debug.Assert(RemotingServices.IsTransparentProxy(robj));
> >
> > If the assertion fails, you don't have a remote object instance.
> >
> > 3) Instantiate your object using Activator.GetObject() instead of using
the
> > config file to declare the wellknown type. This will assure you that you
get
> > a proxy and that you'll get an exception if the server isn't running.
> >
> > Hope that helps -
> > Ken
> >
>
- Next message: Ken Kolda: "Re: Remoting Performance over a WAN with HTTP"
- Previous message: webbarbarian: "Re: Remote client is using local object instead of remote object"
- In reply to: webbarbarian: "Re: Remote client is using local object instead of remote object"
- Next in thread: Magne Ryholt: "Re: Remote client is using local object instead of remote object"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|