C#
An object-oriented and type-safe programming language that has its roots in the C family of languages and includes support for component-oriented programming.
11,006 questions
This browser is no longer supported.
Upgrade to Microsoft Edge to take advantage of the latest features, security updates, and technical support.
I am trying to add some tags to the Header of a SOAP request, but I cannot insert this tag:
<ReplyTo xmlns="http://www.w3.org/2005/08/addressing">
<Address>http://www.w3.org/2005/08/addressing/anonymous</Address>
</ReplyTo>
I tried to insert it like this:
string cValue = "<Address>http://www.w3.org/2005/08/addressing/anonymous</Address>";
AddressHeader oReplyTo = AddressHeader.CreateAddressHeader("ReplyTo",
"http://www.w3.org/2005/08/addressing",
cValue);
But I got this result:
<ReplyTo xmlns="http://www.w3.org/2005/08/addressing"><Address>http://www.w3.org/2005/08/addressing/anonymous</Address></ReplyTo>
How can I do it correctly? Is there any other way besides AddressHeader.CreateAddressHeader?
Thanks for your help.