Type in assembly is not marked as serializable

前端 未结 2 1484
醉梦人生
醉梦人生 2021-01-13 19:22

I have an entityClass that I wish to serialize as a clone. But this class has a reference assembly from a custom framework which I don\'t have the access to the

2条回答
  •  误落风尘
    2021-01-13 19:41

    If you have PropertyChanged event then set it to [NonSerialized] in all objects(classes) you will Serialize.

        [field: NonSerialized]
        public event PropertyChangedEventHandler PropertyChanged;
    

提交回复
热议问题