Search code examples
wpfvnc

VNC control for WPF application


I'm looking for a control that will allow me to host a VNC client session on a WPF window. Initial Googling has yielded nothing for WPF, only WinForms, so if nobody can point me to a WPF control, I would appreciate any advice on using a WinForms VNC control in a WPF application. That is, how can I host a VNC client session in a WPF application?


Solution

  • I recommend going with the WinForms control in a WPF applications approach. It's really pretty simple.

    • Add WindowsFormsIntegration reference to your project
    • Add a WinForms integration element in your XAML:

      <WindowsFormsHost Name="host"/>
      
    • Add your WinForms control to that element in the code-behind:

      host.Child = new WinFormsControl();