In order to fix the connection error, go to Start > Control Panel > System and Security > Windows Firewall > Allow a program through Windows Firewall and check the box next to AIM. If you can't find the application in the Allowed programs and features window, press the Allow another program button, navigate to the installation directory, select the executable file and press Add. After that, from the Advanced Settings select Inbound Rules > New Rule. Check the Port box, click Next, select All local Ports and follow the self-explained steps. Also make sure that your security program doesn't block the connection and all applications that may use your Internet bandwidth are closed.
If it doesn't help, go to Start > Control Panel > Network and Internet > Network and Sharing Center > Local Area Connection and click the Disable button. After that reboot your PC and go to Control Panel > Network and Internet > Network Connections, right click on Local Area Connection and select Enable.
If you still receive the connection error, navigate to the official web page and download and install the latest version of AIM.