Search was throwing an error if the user pressed the search button, when the the Step Type Radio button was pressed when no procedures were selected.

B2015-171 Fixed the Library Document Report.
This commit is contained in:
Rich
2015-10-29 15:25:12 +00:00
parent 265cf53f89
commit 8c76185c13
2 changed files with 167 additions and 53 deletions

View File

@@ -1315,13 +1315,16 @@ namespace Volian.Controls.Library
SearchResults = ItemInfoList.GetListFromTransitionSearch(docVersionList, cbxTranFormat.SelectedIndex - 1, cbxTranCategory.SelectedItem.ToString() == "All" ? "" : cbxTranCategory.SelectedItem.ToString(), TypeSearchList);
cmbResultsStyleIndex = 3; // display step text in results
}
AddMessageForEmptyAnnotations();
if (cmbResultsStyleIndex == 3 && cmbResultsStyle.Items.Count == 3) cmbResultsStyleIndex--;
cmbResultsStyle.SelectedIndex = cmbResultsStyleIndex;
DisplayResults();
if (SearchResults != null && SearchResults.Count == 0)
if (SearchResults != null)
{
MessageBox.Show("No Matches Found.", "Search");
AddMessageForEmptyAnnotations();
if (cmbResultsStyleIndex == 3 && cmbResultsStyle.Items.Count == 3) cmbResultsStyleIndex--;
cmbResultsStyle.SelectedIndex = cmbResultsStyleIndex;
DisplayResults();
if (SearchResults != null && SearchResults.Count == 0)
{
MessageBox.Show("No Matches Found.", "Search");
}
}
}
catch (Exception ex)