How do you remove the Trojan horse Downloader.Agent Z?

I removed my hard drive and installed it in another computer as a secondary drive I then ran AVG (free version) this pickedout the files and found I had many Trojan files on my hard drive, one of which was Agent Z. You may be able to run AVG without removing the hard drive but I never tried this because the machine was badly infected.