1

I have an old WinForms app that needs a few new forms, which would benefit greatly from WPF. Following this tutorial:

http://www.switchonthecode.com/tutorials/wpf-tutorial-using-wpf-in-winforms

The project currently targets the .NET 4 Client Profile.

I added a WPF control. However, when I drop a StackPanel into the control in the designer, the designer displays the following error message:

Type universe cannot resolve assembly: System.Design, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a.

Changing the target to the full .NET 4 resolves the issue. However, requiring the full .NET 4 library for a client app seems to defeat the purpose of having a client profile.

Is there a way to accomplish what I want and still target the client profile?

Dave Clemmer
  • 3,741
  • 12
  • 49
  • 72
Eric J.
  • 147,927
  • 63
  • 340
  • 553
  • 1
    You can't drag a WPF into a WinForm Control. You need to put an ElementHost first.. and then you put the WPF element into this control – jcvegan Jan 10 '12 at 17:26
  • I am using an ElementHost as described in the tutorial I reference in my post. – Eric J. Jan 10 '12 at 19:31

0 Answers0