host windows user- control in WPF user control RRS feed

  • General discussion

  • Hello I'm trying to host a windows-user control inside a WPF user control as follows:

     System.Windows.Forms.Integration.WindowsFormsHost host =
            new System.Windows.Forms.Integration.WindowsFormsHost();
        // Create an object of your User control.
        MyUserControl uc_ = new MyUserControl();
        // Assign MyWebcam control as the host control's child.
        host.Child = uc_;
        // Add the interop host control to the Grid
        // control's collection of child controls. ///note pnlWin is a stackPanel


    in the code behind I'm able to manipulate and call my usercontrol's methods however it is not shown on the user control

    Please can someone help me render my user control on the WPF control?

    Wednesday, December 8, 2010 1:44 PM