Hi,
Just wondering if hosting a WindowsFormsHost control in a WPF user control in the following way is a good practice or not:
<DockPanel LastChildFill="True">
<WindowsFormsHost Name="myHost">
</WindowsFormsHost>
</DockPanel>
private class MyWPFUserControl:UserControl
{
private SomeControl ForeignControl; // SomeControl is a Windows Forms Control.
public MyWPFUserControl()
{
ForeignControl = new SomeControl();
}
public void DisplaySomething(String filename)
{
ForeignControl.DisplaySomething(filename);
myHost.Child = ForeignControl;
}
}