//Type 'System.Net.WebRequest+WebProxyWrapper' cannot be serialized. Consider marking it //with the DataContractAttribute attribute, and marking all of its members you want //serialized with the DataMemberAttribute attribute.
WebProxyClass _WebProxy = new WebProxyClass(); _WebProxy.WebProxy = WebRequest.DefaultWebProxy; // This line successfully fetches system proxy var WebProxy_default = _WebProxy.WebProxy; _pipe.RegisterApp(IPC_Client, WebProxy_default); // I get error on this point using System.Net; public class WebProxyClass { public IWebProxy WebProxy { get; set; } }
System.Net.NetworkCredential cr = new System.Net.NetworkCredential("UserName", "Password", "Domain"); WebProxy pr = new WebProxy("127.0.0.1", 8888); pr.Credentials = cr; restRequest.Proxy = pr;
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)