Referencing this answer, I'm attempting to establish a proxy connection for a service reference, but am having trouble verifying that it's actually being used.
In my app.config, I have
<system.net>
<defaultProxy useDefaultCredentials="true">
<proxy
usesystemdefault="False"
proxyaddress="http://proxyaddresst.com:80"
bypassonlocal="False"/>
</defaultProxy>
</system.net>
but would like to be able to list the address of the proxy being used in the program itself, through
Console.WriteLine(DateTime.Now.ToString("hh:mm:ss.fff") + " Proxy: " + ???);
Is there a way to do this? It seems simple, but so did setting up the proxy in the first place, and the program isn't working as expected. I'd like to either verify the proxy is in use (and discount it as necessary) or verify that it isn't (and then look for another way to integrate it).