开发者

DataContract serialization throw an Security exception

开发者 https://www.devze.com 2023-02-19 04:19 出处:网络
I am trying to use DataContractSerialization on WPF and WP7. A开发者_开发百科ll things are good on WPF but not on WP7. When I tryed to serialize an object on wp7, I received an unknown security except

I am trying to use DataContractSerialization on WPF and WP7. A开发者_开发百科ll things are good on WPF but not on WP7. When I tryed to serialize an object on wp7, I received an unknown security exception. Please view the attached source code and help me.

DataContract serialization throw an Security exception

Source code (mediafire)

Thanks.


I had the same issue.

In my scenario, I was trying to serialize a nested class.

I had to remove the nesting and define the class as public, and then it worked.

0

精彩评论

暂无评论...
验证码 换一张
取 消