How to make a plugin enabled software?

Apr 24, 2010 at 9:16 AM


New to MEF and I have some trouble understanding how to make a plugin enabled software.

I keep getting this error "More than one export was found that matches the constraint"

I want to get all exports that is from a specific interface and use them in a collection like fashion but as soon as I get more than one exports I get this error message.

So you out there who knows MEF, what do I have to do to be able to import more than one export of the same type?



Apr 25, 2010 at 4:43 AM

Are you using ImportMany?

public IEnumerable<IPlugin> Plugins { get; set }