Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- namespace MyMainService
- {
- [System.Web.Services.WebServiceBindingAttribute(Name="MyMainServiceImplPortBinding", Namespace="http://webService.main.myService.com/")]
- public partial class MyMainServiceImplService : System.Web.Services.Protocols.SoapHttpClientProtocol {
- public AuthenticationHeader AuthenticationHeaderValue;
- public MyMainServiceImplService() {
- this.Url = "http://.../MyMainServiceImplService";
- }
- [System.Web.Services.Protocols.SoapRpcMethodAttribute("", RequestNamespace="http://webService.main.myService.com/", ResponseNamespace="http://webService.main.myService.com/", Use=System.Web.Services.Description.SoapBindingUse.Literal)]
- [return: System.Xml.Serialization.XmlElementAttribute("return")]
- public string invokeTransaction(string request) {
- object[] results = this.Invoke("invokeTransaction", new object[] {
- request});
- return ((string)(results[0]));
- }
- }
- public class AuthenticationHeader : SoapHeader
- {
- public string UserName;
- public string Password;
- }
- }
- using (MyMainService.BlazeMainServiceImplService client = new MyMainService.MyMainServiceImplService())
- {
- client.AuthenticationHeaderValue = new MyMainService.AuthenticationHeader();
- client.AuthenticationHeaderValue.UserName = "username";
- client.AuthenticationHeaderValue.Password = "pwd";
- ruleServiceResult = client.invokeTransaction(xmlRequest);
- }
Add Comment
Please, Sign In to add comment