To create a Uri from a string you can do this:
Uri u = new Uri(\"example.com\");
But the problem is if the string (like the one above) does
Interestingly, although Uri and UriBuilder completely mangle any url without a scheme, WebProxy does it right.
Uri
UriBuilder
WebProxy
So just call:
new WebProxy(proxy.ProxyServer).Address