Be sure to address issues as to why moisture is getting to the wood (and into the walls if this is the case) and causing it to rot. In your case, it looks like their are more than a few miles on that trim and it has happened over time?
There are also epoxy products that can come in handy for hard to replace or intricately shaped pieces of wood. I first starting using products from this company restoring old sailboats years ago. There are others though.
http://www.abatron.com/cms/
Obviously, good epoxy resins are expensive and probably not indicated where you can just switch out the trim.