none
Invalid enum value '' cannot be deserialized into type 'OptionType' RRS feed

  • Question

  • Hi

    I have an Enum and I have XSD validation for this

     public enum OptionType : int
        {
            [EnumMemberAttribute()]
            NONE = 1,

            [EnumMemberAttribute()]
            A = 2,
        }

    but i want to pass <ns1:OrderOption></ns1:OrderOption> String.Empty to my service. How do i enable empty string in my XSD

     <xs:restriction base="wsDt:NormalizedStringType">
          <xs:enumeration value="NONE" />
          <xs:enumeration value="A" />     
        </xs:restriction>

    Thanks

    Wednesday, January 30, 2013 1:50 PM

All replies