private void Window_Loaded(object sender, RoutedEventArgs e) { WindowsFormsHost host = new WindowsFormsHost(); ZedGraphDiagnosticsControl.DiagnosticsControlZedGraph graph = new ZedGraphDiagnosticsControl.DiagnosticsControlZedGraph(); host.Child = graph; gridLayout.Children.Add(host); this.Width = System.Windows.Forms.Screen.PrimaryScreen.Bounds.Width; this.Height = System.Windows.Forms.Screen.PrimaryScreen.Bounds.Height; graph.Disposed += new EventHandler(graph_Disposed); }