protected void LB_Click(object sender, EventArgs e) { //attempt to cast the sender as a label ImageButton lbl = sender as ImageButton; WebService2SoapClient client = new WebService2SoapClient(); Person person = client.findperson(Convert.ToInt32(lbl.ID)); Label4.Text = Convert.ToString(person.id); Label5.Text = Convert.ToString(person.name); Label6.Text = Convert.ToString(person.phone); }
public ActionResult Index(string cedulaPersona) { WebService2SoapClient consumoCedula = new WebService2SoapClient(); if (consumoCedula.ValidarCedula(cedulaPersona) == true) { ViewBag.Result = "Cédula es válida"; } else { ViewBag.Result = "Cédula no es válida"; } return(View()); }
static void Main(string[] args) { WebService2SoapClient service = new WebService2SoapClient(); Console.WriteLine("What file should be read? "); string UserInput = Console.ReadLine(); Console.WriteLine("You have entered: " + UserInput); service.GetWebsiteHtml(UserInput); Console.WriteLine("File contains: " + service.GetWebsiteHtml(UserInput)); Console.WriteLine("Press any key"); Console.ReadKey(); Console.WriteLine("Here is objects in database:"); foreach (string s in service.objects2()) { Console.WriteLine(s); } Console.WriteLine(); Console.ReadKey(); }
public WebService2SoapClient() : base(WebService2SoapClient.GetDefaultBinding(), WebService2SoapClient.GetDefaultEndpointAddress()) { this.Endpoint.Name = EndpointConfiguration.WebService2Soap.ToString(); ConfigureEndpoint(this.Endpoint, this.ClientCredentials); }
private static System.ServiceModel.EndpointAddress GetDefaultEndpointAddress() { return(WebService2SoapClient.GetEndpointAddress(EndpointConfiguration.WebService2Soap)); }
private static System.ServiceModel.Channels.Binding GetDefaultBinding() { return(WebService2SoapClient.GetBindingForEndpoint(EndpointConfiguration.WebService2Soap)); }
public WebService2SoapClient(EndpointConfiguration endpointConfiguration, System.ServiceModel.EndpointAddress remoteAddress) : base(WebService2SoapClient.GetBindingForEndpoint(endpointConfiguration), remoteAddress) { this.Endpoint.Name = endpointConfiguration.ToString(); ConfigureEndpoint(this.Endpoint, this.ClientCredentials); }
public WebService2SoapClient(EndpointConfiguration endpointConfiguration) : base(WebService2SoapClient.GetBindingForEndpoint(endpointConfiguration), WebService2SoapClient.GetEndpointAddress(endpointConfiguration)) { this.Endpoint.Name = endpointConfiguration.ToString(); ConfigureEndpoint(this.Endpoint, this.ClientCredentials); }