How can i define the Message contract to get this XML SOAP format?
Schema:
<List>
<Exclusions>
<ExclusionID>123</ExclusionID>
<ExclusionID>656</ExclusionID>
</Exclusions>
</List>
I created the class file as mention below but it gives the response different
<DataContract> _
Public Class List
''' <remarks/>
Private _exclusions As Exclusions
<DataMember()> _
Public Property Exclusions() As Exclusions
Get
Return _exclusions
End Get
Set(ByVal value As Exclusions)
_exclusions = value
End Set
End Property
End Class
<DataContract>
Public Class Exclusions
<DataMember>
Public ExclusionID As ExclusionID()
End Class
<MessageContract>
Public Class ExclusionID
<MessageBodyMember(Name:="")>
Public Value As String
End Class
My response is like this:
<List >
<Exclusions >
<ExclusionID>
<ExclusionID>
<Value>123</Value>
</ExclusionID>
<ExclusionID>
<Value>145</Value>
</ExclusionID>
</ExclusionID>
</Exclusions>
</List>
How to achive the proper message using Message contract?