Endpoint Address changing

Posted by Nagababu under WCF on 9/11/2011 | Points: 10 | Views : 1899 | Status : [Member] | Replies : 2
Hi All,

In the Web.config file if changed the address of the endpoint, throughing error when the proxy is address executed saying as there is no reference as specified. I need to get updated address in codebehind side(C#).
But i am getting old address only.

Using Basichttp binding.

Please help me out.

Thanks ,
Nagababu.




Responses

Posted by: Blessyjees on: 9/22/2011 [Member] Bronze | Points: 25

Up
0
Down
Hi,

You can assign endpoint address from code side
 BasicHttpBinding basicHttpBinding = new BasicHttpBinding();

EndpointAddress endPoint = new EndpointAddress(<specify your address>);
using (ServiceProxy = new ServiceProxy.ServiceClient(basicHttpBinding, endPoint))
{
ServiceProxy.Open();
ServiceProxy.FunctionNAme()// which function you want to call
}


Blessy Baby
Digitalmesh Softech pvt Ltd
https://blessybaby.wordpress.com/

Nagababu, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: smsaxena19-12050 on: 9/28/2011 [Member] Starter | Points: 25

Up
0
Down
You need to Update the Service Reference then it will automatically show the changes.

Nagababu, if this helps please login to Mark As Answer. | Alert Moderator

Login to post response