This project has moved. For the latest updates, please go here.

MEF, WPF and injecting data templates

Feb 10, 2010 at 3:03 PM

I'm not sure if this will be of any use to anyone else however we had a scenario where we wanted to inject data templates into a window in WPF. The data templates will be written by third parties so we can't include the data templates directly in the window.

I've documented the approach we used at:

Feel free to suggest improvements or even laugh at the requirement to do this :)


Feb 12, 2010 at 5:37 PM

You may want to check the following sample,

it use different WPF composition style (including composition of data using data template)

the sample is written using VS 2010