none
我有个数据契约在客户端突然不见了,请问怎么回事? RRS feed

  • 问题

  • 我有个数据契约

    [DataContract]
        public class Proddepinfo
        {
            

            [DataMember]//数据成员标记
            public string Myprodno
            {
                get;
                set;
            }
            [DataMember]//数据成员标记
            public string Myprodname
            {
                get;
                set;
            }
            [DataMember]//数据成员标记
            public string Myprodsize
            {
                get;
                set;
            }
            [DataMember]//数据成员标记
            public string Mylastadd
            {
                get;
                set;
            }
            [DataMember]//数据成员标记
            public double Myretailprice
            {
                get;
                set;
            }
            [DataMember]//数据成员标记
            public int Mybelongto
            {
                get;
                set;
            }
            [DataMember]//数据成员标记
            public int Myysbl
            {
                get;
                set;
            }

        }



        [DataContract]
        public class GetProddepinfoFault
        {

            private string operation;
            private string problemType;

            [DataMember]
            public string Operation
            {
                get { return operation; }
                set { operation = value; }
            }

            [DataMember]
            public string ProblemType
            {
                get { return problemType; }
                set { problemType = value; }
            }

        }

    即使我加了这个在客户端的代理那里找不到

      [ServiceContract]
        [ServiceKnownType(typeof(Proddepinfo))]

    public interface IService1
        {

            [OperationContract]
            [FaultContract(typeof(GetProddepinfoFault))]
            MyList GetProddep();

           
        }               

    2013年3月5日 9:34

答案

全部回复