Nikki Nagarkar

Nikki Nagarkar

  • 1.8k
  • 58
  • 2.4k

how to take binding address from App.config

Feb 6 2019 11:38 PM
i have consumed the service which has automatically created the binding in app.config file
 
binding="basicHttpBinding" bindingConfiguration="basic" contract="CreateFormReqSerRefV2.CreateFormInterface"
name="CreateFormRequestResponder" />
binding="basicHttpBinding" bindingConfiguration="basic" contract="GetFormInterface"
name="GetFormRequestResponder" />
 
I have to use this address value from name of endpoint in my code .
 
PLease dont ask me add Key in appsetting ,i already know this way i want to avoid redundancy
 
CreateFormRequestResponderKey" value=""https://XYZ""/>
CreateFormUrlAddress=ConfigurationManager.AppSettings["CreateFormRequestResponderKey"]); --------->i dont want through key in aap setting want value from endpoint name

Answers (1)