Change prefix namespace WCF envelope request

207 Views Asked by At

I have a question, I was wondering if is there an anyway to change the namespace prefix for the WCF Soap 1.2 request in c#?

I have tried to apply MessageFormatter, but this is just applied in the response structure, and I am looking for an option in the request.

Thank you.

2

There are 2 best solutions below

2
On BEST ANSWER

MessageFormatter can be done on Server side also.And you can change this with MessageEncoder but it would cause many problems.

The link below tells you how to do this on server side using a MessageFormatter and also the downside of a MessageEncoder: https://www.vanacosmin.ro/Articles/Read/WCFEnvelopeNamespacePrefix

Thanks.

0
On

We might be talking about different things here. But you can change the namespace when creating the service reference in Visusal Studio. enter image description here