private void FindReplace(object sender, RoutedEventArgs e) // btnFindReplace click event { FindReplace findReplaceWindow = new FindReplace(new TextRange(page1.Document.ContentStart, page1.Document.ContentEnd), page1); findReplaceWindow.Show(); }
void System.Windows.Markup.IComponentConnector.Connect(int connectionId, object target) { switch (connectionId) { case 1: this.findReplaceWindow = ((TextEd.FindReplace)(target)); #line 11 "..\..\FindReplace.xaml" this.findReplaceWindow.Closing += new System.ComponentModel.CancelEventHandler(this.WindowIsClosing); #line default #line hidden return; case 2: this.find = ((System.Windows.Controls.MenuItem)(target)); #line 24 "..\..\FindReplace.xaml" this.find.Click += new System.Windows.RoutedEventHandler(this.MenuItemClick); #line default #line hidden #line 29 "..\..\FindReplace.xaml" this.find.MouseEnter += new System.Windows.Input.MouseEventHandler(this.MouseEnterToBold); #line default #line hidden #line 30 "..\..\FindReplace.xaml" this.find.MouseLeave += new System.Windows.Input.MouseEventHandler(this.MouseLeaveToNormal); #line default #line hidden return; case 3: this.replace = ((System.Windows.Controls.MenuItem)(target)); #line 34 "..\..\FindReplace.xaml" this.replace.Click += new System.Windows.RoutedEventHandler(this.MenuItemClick); #line default #line hidden #line 38 "..\..\FindReplace.xaml" this.replace.MouseEnter += new System.Windows.Input.MouseEventHandler(this.MouseEnterToBold); #line default #line hidden #line 39 "..\..\FindReplace.xaml" this.replace.MouseLeave += new System.Windows.Input.MouseEventHandler(this.MouseLeaveToNormal); #line default #line hidden return; case 4: this.lbFind = ((System.Windows.Controls.Label)(target)); return; case 5: this.lbReplace = ((System.Windows.Controls.Label)(target)); return; case 6: this.txtBoxFind = ((System.Windows.Controls.TextBox)(target)); #line 66 "..\..\FindReplace.xaml" this.txtBoxFind.TextChanged += new System.Windows.Controls.TextChangedEventHandler(this.Highlight); #line default #line hidden return; case 7: this.txtBoxReplaceWith = ((System.Windows.Controls.TextBox)(target)); return; case 8: this.btnConfirm = ((System.Windows.Controls.Button)(target)); #line 83 "..\..\FindReplace.xaml" this.btnConfirm.Click += new System.Windows.RoutedEventHandler(this.Replace); #line default #line hidden return; case 9: this.checkBoxCaseSensitive = ((System.Windows.Controls.CheckBox)(target)); return; } this._contentLoaded = true; }