Computer viruses can be transmitted by sharing infected files via email or instant messages. They can replicate and spread automatically without you doing anything.
Whenever you share data with another computer or computer user, you risk exposing your computer to potential viruses. Since there are many ways you can share data, there are many ways a virus can be transmitted. These include:
Opening an infected file attached to an email message
Opening an infected file sent to you via an instant messaging program
Launching an infected program file downloaded from the Internet
Sharing a floppy disk that contains an infected file
Sharing a computer file over a network that contains an infected file