Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
195
Can you load an exe into a content pane tab
posted

We are trying to make a robust WPF application where we have several add-in in separate exe's. We can load them into the main window of the application but we would really like to be able to load the exe's into multiple tabs.

Doable? If so how?

Actually we are trying to do something like this: https://msdn.microsoft.com/en-us/magazine/dn519924.aspx but where as they are using a regular tab we would want to use the docking and probably put each out of process object in a content pane tab.

Parents
  • 54937
    Offline posted

    I'll just expand a bit on what Tacho said. Basically the sample you are referring to is using WPF addins which ultimately just host the view in an AddInHost (an internal HwndHost derived class in the System.Windows.Presentation assembly). The xamDockManager can contain HwndHost derived elements just like they can be hosted in any other element and just as they are hosted in the tabcontrol in that sample. If you're question is more about how to in an MVVM way define content for contentpanes then perhaps you would look at Brian's blog post here.

    Note, HwndHosts are separate hwnds and as such will mean air space issues in WPF as described here in the context of WindowsFormsHost (which is just another type of hwndHost). The xamDockManager will act a little differently when you are using hwndhosts - e.g. the unpinned flyout will be displayed in a popup to ensure the content is above any hwndhosts, animations of unpinned panes that contain an hwndhost will be disabled, etc.

Reply Children