The best way to prevent a virus/trojan etc from entering your PC through pen drives is to use address bar to open the them instead of double clicking the pen drive. A lot of people are unaware of this.When i was unaware of this, I used to search *.* in the pen drive with hidden files enabled. A virus cant run by itself if you are not executing it by some way. This feels like Harry potter teaching Dumbledore's army the Expelliarmus spell

. Many people will say that they know this but many wont. This is most simple and yet very effective way prevent viruses from entering your computer.
Also many virus/Trojans can be manually removed if the view hidden files and system files are enabled.Usually .bat , .exe, .vbs types of files are viruses. Also remember to remove autorun.inf file.
I hope this information helps.