can u try this, create an object of serviceclient and then use the EndPoint.Address.Uri property
how to get the service URL or address with the service reference name WCF and C#
-
02-06-2022 - |
Question
How can i get the address of the service reference. For instance i have a service reference named profile and its address is :
http://hostname/services/profile.svc
How can i get get this address in c# by specifying the service name, in this case "profile"? so far i have tried
new profile.profileServiceClient()
and tried to find anything useful from the watch list but didn't get anything useful.
This might not be a good question but its very useful for me. Will really appreciate your help.
Solution
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow