The good functionality of Yahoo! Messenger depends on your browser's proper configuration. This error usually appears when Internet Explorer is your default browser and when you are using it with the wrong settings.
Now, this is what you can do. Download and install the latest version of Internet Explorer, http://internet-explorer.software.informer.com/ restart your computer and reset your web browser configuration, by following the next steps: open Internet Explorer, go to Tools and Internet Options. Select the Advanced tab, click the two Reset buttons, Apply and OK. Another thing you can do is to check if Windows Firewall isn't blocking Yahoo! Messenger. Go to Start, open Control Panel, hit Windows Firewall and if Yahoo! Messenger appears in the list of blocked applications, add it to the exception list so it can use your Internet connection with no questions.