ISoapSerializerPtr Serializer;
ISoapReaderPtr Reader;
ISoapConnectorPtr Connector;
// Connect to the service.
Connector.CreateInstance(__uuidof(HttpConnector30));
Connector->Property["EndPointURL"] = "http://127.0.0.1:80/MyWeb/testWeb.WSDL";
Connector->Connect(); // Begin the message.
Connector->Property["SoapAction"] = "http://org.kylin.test/MyWeb/testWeb.Add";
Connector->BeginMessage();
// Create the SoapSerializer object.
Serializer.CreateInstance(__uuidof(SoapSerializer30));
// Connect the serializer object to the input stream of the connector object.
Serializer->Init(_variant_t((IUnknown*)Connector->InputStream));
// Build the SOAP Message.
Serializer->StartEnvelope("","","");
Serializer->StartBody("");
Serializer->StartElement("Add","http://org.kylin.test/MyWeb/","","");
Serializer->StartElement("a","","","");
Serializer->WriteString("2");
Serializer->EndElement();
Serializer->StartElement("b","","","");
Serializer->WriteString("13");
Serializer->EndElement();
Serializer->EndElement();
Serializer->EndBody();
Serializer->EndEnvelope();
// Send the message to the XML Web service.

Connector->EndMessage(); 
//最后一句异常了,有知道原因的吗?