What you got is not a virus and it is unlikely any anti-virus, free or paid, would have prevented it.
You got scareware from a malicious web site. That means you visited the web site yourself and you allowed the malware to take hold.
I am very disapointed with all the Avast antivirus. When i just purchase my computer for only 1 month only with Avast! free antivirus software installed myself, my computer have a fake antivirus automatically come out on my monitor screen.
When the fake antivirus software appear, I can't use the Control Panel to remove it, and when I am using my computer, it sometimes suddently the computer automatically do a illegal shut down.
Folks, avoid ALL free antivirus software expacially any version & any license of Avast! antivirus. When you don't want to pay for the unique protection features, then you don't get it. Use Microsoft Security Essentials because a lot of people says MSE is the good antivirus expacially in the Windows 7 forums forum.
When you are intested to buy antivirus software, buy Norton 360. The Norton has four main unique features: One, PC security. Two, Identity protection. Three, Backup. Four, PC tuneup.
You know why I don't use Avast! antivirus?