SoapHeaders???
-
I have no problems sending a soap header in my call but how do i read the soap
header response. This is using the proxy generated class I modified it to send
the header info. Heres an excerpt of what i have:private SessionInfo objHeader = null; [System.Web.Services.Protocols.SoapHeader "sessionObject",Direction=SoapHeaderDirection.Out)] [System.Web.Services.Protocols.SoapRpcMethodAttribute("execute", RequestNamespace=_RequestNS, ResponseNamespace=_RequestNS)] [return: System.Xml.Serialization.SoapElementAttribute("result")] public string execute(string sql) { object[] results = this.Invoke("execute", new object[] {sql}); return ((string)(results[0])); }
The sessionObject is a property that set's the private objHeader. How in the world
do i read the header coming back from the soap call:confused: This is what the header object looks like:[XmlRoot("SessionInfo")] public class SessionInfo : SoapHeader { /// [XmlAttribute("xmlns")] public string xmlns=@"http://www.aspconverters.com/SessionInfoHeader"; /// /// user id from succesful login /// [XmlElement(ElementName="SESSION_USER")] public string SESSION_USER = ""; /// /// session id from succesful login /// [XmlElement(ElementName="SESSION_ID")] public string SESSION_ID = ""; [XmlElement(ElementName="SESSION_SIGNATURE")] public string SESSION_SIGNATURE = ""; [XmlElement(ElementName="messageID")] public string messageID = ""; [XmlElement(ElementName="id")] public string id = ""; }