Comment There is a whole book on how to do this (Score 2) 236
Working Effectively with Legacy Code
http://www.amazon.co.uk/Working-Effectively-Legacy-Code-ebook/dp/B005OYHF0A/ref=sr_1_1?ie=UTF8&qid=1344190021&sr=8-1
Disclaimer: "These opinions are my own, though for a small fee they be yours too." -- Dave Haynie