My Application is developed using WinForms. Is it possible to host the WPF DataGrid
, Button
, ListBox
, ComboBox
etc in WinForms User Controls?
相关问题
- VNC control for WPF application
- How to use Control.FromHandle?
- How do I bind a DataGridViewComboBoxColumn to a pr
- WPF Binding from System.Windows.SystemParameters.P
- Partial Form Class C# - Only display code view for
Yes, it's possible using the
ElementHost
control in Winforms and hosting WPF content inside of it.I would not mix WinForm and WPF unless absolutely necessary. Though, Microsoft has provided the way to use WPF control in WinForm and vice-versa but it doesn't always give good result. WF and WPF renders the controls in different ways and you may face multiple issues including performance and UI flickering depending on the way they have been used.
If you really want to use WPF control in WF then use ElementHost control.