private void Search(int searchDirection) { try { if (!_editor.Search(tscbKeyValue.SelectedIndex, searchDirection, tscbComparer.Text, tstbSearch.Text)) { MessageBox.Show("No match found.", "Dune 2000 Editor"); } } catch (Exception e) { MessageBox.Show("Error encountered finding match\n\n{0}: {1}\n\nStack Trace:\n{2}".F(e.GetType(), e.Message, e.StackTrace), "Dune 2000 Editor"); } }