I have researched all MSDN information on SoapHeaders and have built the solution the way Microsoft says to. That actually happens to be my problem. What they suggest is that you create a class derived from the SoapHeader class and include a string member to hold the value for the header. The problem is that the SoapHeader class creates the tag from the name of your derived class and then creates another tag off of your variable name within that class. I need something different, some other answer. Below is an example:

#public __gc class HostArea : public SoapHeader
public: String * Value;

You attach it to your WebMethod as so:

#HostArea * myHeader;

MyTransactionResult * MyTransactionRequest(String * GUID, String * XMLTransaction, Int32 Loc);#

You call it inside the class as so:

#String * sHostName = S"";
char szTempHostName[50];

GetRRNhost (szTempHostName, sizeof(szTempHostName));
sHostName = &szTempHostName[2];
myHeader->Value = sHostName;#

And it Produces:


This is a problem because what the receiving code on the server wants to see is this:


Has anyone ever had to deal with this? Does anyone know how to set the SoapHeader without using a class that produces multiple tags?