大家给看看这个Remoting的配置文件
使用代码开启通道,加载远程对象都没有问题,但换到配置文件中以后就不成了
错误如下:
---------------------------
System.Security.SecurityException: 不允许类型 System.DelegateSerializationHolder 和从中派生的类型(例如 System.DelegateSerializationHolder)在此安全级别上被反序列化。
---------------------------
网上找到的相关解决方案如下(不能解决...):
------------------------------
http://topic.csdn.net/t/20051226/21/4482753.html
http://www.cnblogs.com/zhengyun_ustc/archive/2005/05/18/158276.html
------------------------------
配置文件全部内容如下(测试用的Test对象里边什么都没做,可正常调用):
--------------------------------
<?xml version= "1.0 " encoding= "utf-8 " ?>
<configuration>
<system.runtime.remoting>
<application>
<channels>
<channel ref= "tcp " port= "8000 "/>
<serverProviders>
<provider ref= "wsdl " />
<formatter ref= "binary " typeFilterLevel= "Full " />
<formatter ref= "soap " typeFilterLevel= "Full " />
</serverProviders>
<clientProviders>
<formatter ref= "binary " />
</clientProviders>
</channels>
<service>
<wellknown mode= "Singleton "
type= "My.Login, User.Login "
objectUri= "Login " />
</service>
<service>
<wellknown mode= "Singleton "
type= "My.Test, User.Test "
objectUri= "Test " />
</service>
<lifetime leaseTime= "80000M " sponsorshipTimeout= "80000M " renewOnCallTime= "80000M "/>
</application>
</system.runtime.remoting>
</configuration>
[解决办法]
Up
[解决办法]
<formatter ref= "binary " typeFilterLevel= "Full " />
<formatter ref= "soap " typeFilterLevel= "Full " />
这个在两端都要有
[解决办法]
http://www.cnblogs.com/wayfarer/archive/2004/07/30/28723.html
建主看看吧!!很不
[解决办法]
看了你这个配置文件 2个字 乱七八糟
给你看看目前我用的 客户端激活模式
server
<system.runtime.remoting>
<application>
<service>
<activated type= "ServerObject.Data.DataOperate10g, ServerObject " objectUri= "DataOperate10g.soap " />
</service>
<channels>
<channel ref= "http " port= "8888 ">
</channel>
</channels>
</application>
</system.runtime.remoting>
client
<system.runtime.remoting>
<application>
<client url= "http://192.168.202.198:8888 ">
<activated type= "ServerObject.Data.DataOperate10g, ServerObject " />
</client>
</application>
</system.runtime.remoting>