Calling my WPF application from Microsoft Robotics
I have an application using Microsoft Robotics Development Studio that calls a winform. I want to change my application to call a WPF application. I have a WPF with two files App.xaml and Window1.xaml and App.xaml.cs and Window1.xaml.cs. From my MRDS application I have tried to call the WPF application using the following code I found in the WPF Unleashed book.
App app = new App();
app.StartupUri = new Uri("Window1.xaml", UriKind.Relative);
app.Run();
AND
App app = new App();
Window1 mainWindow = new Window1();
mainWindow.Show();
app.Run(mainWindow);
This compiles and runs however after initializin App it hangs when it tries to initialize Window1. What am I doing wrong? Is there any documenation that can help me?
|