Using the example below, I was able to pass a basic SOAP alert to the php web service on the other end. PHP.net/Soapclient has a simple working example, but in csharp I found this link to solve my problem.
link
Michaelis.MockService is an extracted Webservice library, you can see an example of how to do this:
link Mono project website.
Michaelis.MockService service = new Michaelis.MockService();
// Create the network credentials and assign
// them to the service credentials
NetworkCredential netCredential = new NetworkCredential("Inigo.Montoya", "Ykmfptd");
Uri uri = new Uri(service.Url);
ICredentials credentials = netCredential.GetCredential(uri, "Basic");
service.Credentials = credentials;
// Be sure to set PreAuthenticate to true or else
// authentication will not be sent.
service.PreAuthenticate = true;
// Make the web service call.
service.Method();
source
share