internal SocketEx createSocket() { // create SocketEx object according to proxy settings SocketEx sock = null; try { sock = new SocketEx(currentProxy.ProxyType, currentProxy.ProxyServer, currentProxy.ProxyPort, currentProxy.ProxyUser, currentProxy.ProxyPassword); sock.SetTimeout(0x30d40); } catch (Exception sockError) { AddLogLine("createSocket error: " + sockError.Message); } return sock; }