A major headache in this regard are Adobe’s Flash objects/libraries, it’s nigh impossible to delete for example, Flash?.ocx et al from your Windows system folder.
For this and all related issues regarding in use system protected files, folders etc. comes a wonderful little utility which admittedly doesn’t come handy on a daily basis, but it does get its money’s worth (especially since it’s free), called Unlocker by Cedrick Collomb. I recommend it wholeheartedly.
Worthy of note is that there are actually plenty of similar utilities out there (who would have guessed ;-)), and of course Microsoft has a poor man’s command line utility called inuse that does a similar job.