Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Visual Studio/C#: Nuget Unable to connect to remote server

Tags:

nuget

In MS Visual studio, I'm trying to install Nuget packages into my solution.

When I choose the option "Manage Nuget Packages for Solution" and attempt to install a package, I get the message "Unable to connect to the remote server".

I do have Internet connection so do not understand why I always get this message.

Is anyone aware of some steps that can be taken to rectify this issue?

Thanks

like image 744
TheWommies Avatar asked Jul 19 '12 03:07

TheWommies


People also ask

Can I use Visual Studio for C?

The Microsoft C/C++ for Visual Studio Code extension supports IntelliSense, debugging, code formatting, auto-completion. Visual Studio for Mac doesn't support Microsoft C++, but does support . NET languages and cross-platform development.

Is Visual Studio C C++ free?

Visual Studio Community. A fully-featured, extensible, free IDE for creating modern applications for Android, iOS, Windows, as well as web applications and cloud services.


1 Answers

Clearing HTTP_PROXY worked for me.

Let me fix it myself

Important: This section, method, or task contains steps that tell you how to modify the registry. However, serious problems might occur if you modify the registry incorrectly. Therefore, make sure that you follow these steps carefully. For added protection, back up the registry before you modify it. Then, you can restore the registry if a problem occurs. For more information about how to back up and restore the registry, click the following article number to view the article in the Microsoft Knowledge Base: 322756 How to back up and restore the registry in Windows

To reset your Internet Explorer proxy settings yourself, follow these steps:

  1. On Windows XP, click Start, or on Windows Vista or Windows 7, click , and then click Run. On Windows 8 or Windows 8.1, to access the Run command, press the Windows logo key Windows logo key + R. Or, swipe in from the right edge of the screen, and then tap Search (or if you are using a mouse, point to the upper-right corner of the screen, move the mouse pointer down, and then click Search). Type Run in the search box, and then tap or click Run.
  2. In the Run text box, copy (CTRL+C) and paste (CTRL+V) or type the following: reg add "HKCU\Software\Microsoft\Windows\CurrentVersion\Internet Settings" /v ProxyEnable /t REG_DWORD /d 0 /f
  3. Click OK.
  4. On Windows XP, click Start , or on Windows Vista or Windows 7, click , and then click Run. On Windows 8 or Windows 8.1, to access the Run command, press the Windows logo key Windows logo key + R. Or, swipe in from the right edge of the screen, and then tap Search (or if you are using a mouse, point to the upper-right corner of the screen, move the mouse pointer down, and then click Search). Type Run in the search box, and then tap or click Run.
  5. In the Run text box, copy (CTRL+C) and paste (CTRL+V) or type the following: reg delete "HKCU\Software\Microsoft\Windows\CurrentVersion\Internet Settings" /v ProxyServer /f
  6. Click OK.

From http://support.microsoft.com/kb/2289942 Thanks @Sandy

like image 147
ben Avatar answered Sep 28 '22 02:09

ben