"Pavel Gusak" <pgusak@ukr.net> wrote in message
news:u4ndtB6sDHA.1884@TK2MSFTNGP10.phx.gbl...
> Yes, thank you. I've already read it. However, it happens even I compile
all
> components by .NET 1.0 compilers, so it does not seem to be related to
1.1.
>
> BTW, I do not use .config file to configure client side. I use
> RemotingConfiguration.RegisterWellKnownClientType(). Is that ok?
>
> Thank you again.
>
> Pavel
>
> "Sunny" <sunnyask@icebergwireless.com> wrote in message
> news:#1a3Dm5sDHA.2360@TK2MSFTNGP09.phx.gbl...
> > Hi Pavel,
> > please, read this:
> >
http://www.ingorammer.com/RemotingFAQ/Changes2003.html > >
> > Hope that helps
> > Sunny
> >
> > In article <#stDEf2sDHA.1060@TK2MSFTNGP12.phx.gbl>, pgusak@ukr.net
> > says...
> > > I'm trying to use Remoting to receive notifications from another .NET
> > > component.
> > > I'm successfully accessing remoted object (created by the server app),
> but
> > > can not pass a reference to my object as a "callback".
> > >
> > > I get the following error message:
> > >
> > > An unhandled exception of type
> > > 'System.Runtime.Serialization.SerializationException' occurred in
> > > mscorlib.dll
> > >
> > > Additional information: Because of security restrictions, the type
> > > System.Runtime.Remoting.ObjRef cannot be accessed.
> > >
> > > Here is my sources:
> > >
> > > // event target interface
> > > public interface EventTarget
> > > {
> > > [OneWayAttribute()]
> > > void NotifyECRegistered(int ecID);
> > > }
> > >
> > > // event sink class
> > > public class EventManager : MarshalByRefObject, EventTarget
> > > { ... }
> > >
> > > // hosting object
> > > public class EventConsumer : MarshalByRefObject
> > > {...
> > > public void RegisterTarget(EventTarget target, string condition)
> > > {
> > > targets.Add(target, condition);
> > > }...
> > > }
> > >
> > > // client
> > >
> > >
RemotingConfiguration.RegisterWellKnownClientType(typeof(EventConsumer),
> > > http://localhost:8989/EventConsumer.rem);
> > >
> > > EventConsumer consumer = new EventConsumer();
> > > EventManager manager = new EventManager();
> > >
> > > consumer.RegisterTarget(manager, "");
> > >
> > > The error occurs on the last line.
> > >
> > > What am I doing wrong?
> > >
> > > Many thanks!
> > >
> > >
> > >
>
>