Reputation: 22652
I have a WCF service as shown below. It generates the following WSDL.
Based on the naming conventions in the organization, I need the element name to be "tns:GetDataUsingDataContractInput" instead of ="tns:GetDataUsingDataContract" (i.e, the word “Input” need to be appended. )
How can we do it using C# Code? Also, the corresponding xsd generated should reflect this change.
[ServiceContract]
public interface IService1
{
[OperationContract]
CompositeType GetDataUsingDataContract(CompositeType composite);
}
WSDL
REFERENCE
Upvotes: 1
Views: 1773
Reputation: 3922
I'm not entirely sure I understand your question but could it be as simple as doing:
[ServiceContract]
public interface IService1
{
[OperationContract(Name="GetDataUsingDataContractInput")]
CompositeType GetDataUsingDataContract(CompositeType composite);
}
Upvotes: 1