|
-
Aug 7th, 2008, 04:40 PM
#1
Thread Starter
New Member
[2008] How to open a WPF application from a Form
How would I open a WPF(xaml) application from a windows form?

I want the "Mampi paint" button to open up the wpf application I have in this project called, "UserControl1.xaml".
How would I do that?
Thanks
-
Aug 7th, 2008, 06:28 PM
#2
Re: [2008] How to open a WPF application from a Form
From your terminology it's not clear what you actually want. Are you saying that you want to click that button and start a whole separate application, or that you want to display a WPF control on your existing Windows Form?
If it's the former then the fact that it's a WPF app is irrelevant. You call Process.Start to run any application, regardless of how it was created.
If it's the latter then you will need to add an ElementHost control to your form from the WPF Interoperability section of the Toolbox, which you can then add WPF controls to. WPF applications have a corresponding WindowsFormsHost control that allows you to embed Windows Forms controls in a WPF Window.
Last edited by jmcilhinney; Aug 7th, 2008 at 06:33 PM.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|