Avoiding Viruses Viruses spread when you launch an infected application or start up your computer from a disk that has infected system files. Computer viruses don't infect files on write-protected disks, and they usually don't infect documents. They don't infect compressed files either.
Viruses behave in different ways.
Some viruses stay active in memory until you turn off your computer. Other viruses stay active only as long as the infected applications is running. Turning off your computer or exiting the application removes the virus from memory, but does not remove the virus from the infected file or disk. Some viruses are programmed specifically to damage the data on your computer by corrupting programs, deleting files, or erasing your entire hard disk. A trojan horse is a program that appears to serve some useful purpose or provide entertainment, which encourages you to run it.