Error message: Cannot connect to server

I`m using Windows XP with McAfee security centre, but with McAfee anti-virus removed.

Avast is set to automatically update once a day, but instead of updating a red box opens with the massage cannot connect to server. If I try to update manually a white box opens with a similar message.

I used Avast without problems for a couple of months and then this problem began. I`ve tried reinstalling the program but to no avail.

Did the manual update work or not?

Into your McAfee firewall settings, the following programs should be allowed to connect:

ashServ.exe (avast! antivirus service)
ashWebSv.exe (avast! Web Scanner) (allow server rights)
ashMaiSv.exe (avast! e-Mail Scanner Service) (allow email rights)
ashUpdSv.exe (avast! Update Service)
avast.setup (avast! Update executable)

No the manual update didn`t work.

The connection to the server is not being blocked by a firewall, those applications all have access.

Let’s try another thing.
Make sure your browser is not set to “Work Offline” (this option is generally in the File menu). If it doesn’t help, try switching the proxy settings from “Auto-detect” to “No proxy” (I’m assuming you’re not connecting to the Internet via proxy).

Left click the avast icon > Settings
Update (Basic) > Details > Proxy

Thats not the problem either.

Im online and everything is as it should be, then 30 seconds later the: Cannot Connect To Server; message comes up. A box says couldnt find: download2.avast.com; but when I type that into the browser the Avast website opens without any problems. Anything else I can try?

Sure, just change (or add) AlwaysConnectedWaitSeconds value into the [InetWD] section of avast4.ini file.
You could set the number of seconds to wait before attempting to update. The default is 30 but it may not be enough in some DSL systems. In this case, you can try increasing this e.g. to 60 (1 minute). That should be enough.
More details here: http://forum.avast.com/index.php?board=2;action=display;threadid=1647