[Tex/LaTex] Install package in MiKTeX

installingmiktexpackages

I'm trying to install new packages on my MiKTeX session with the following path:
Package Manager(admin) from the menu of my computer –> In the box Name I write the name of the package, let say for example fancyhdr –> then I click on + –> but connect failed in tcp_connect. I always receive Failed in tcp_connect().

Please, could someone help me to solve this problem? I can't download any new package. It becomes impossible for me to write a document article.

Best Answer

Check if a) your MPM is allowed to connect to the internet (see your firewall/antivirus settings);

or

b) Are you connecting under a proxy? If so, you must setup the proxy through the menu Repository > Change Package Repository > select "Packages shall be installed from the internet" > Connection settings > (enter your proxy settings in the dialog box)

EDIT: the solution found in this question MikTeX 2.8 Update Error "Windows API error 87" solved the problem.