Added validation and error handling

BETA READY
This commit is contained in:
Robert McRackan 2019-11-15 22:43:04 -05:00
parent e319326c30
commit b9314ac678
7 changed files with 42 additions and 34 deletions

View file

@ -16,7 +16,14 @@ namespace LibationWinForm
private async void IndexLibraryDialog_Shown(object sender, System.EventArgs e)
{
(TotalBooksProcessed, NewBooksAdded) = await LibraryCommands.IndexLibraryAsync(new Login.WinformResponder());
try
{
(TotalBooksProcessed, NewBooksAdded) = await LibraryCommands.IndexLibraryAsync(new Login.WinformResponder());
}
catch
{
MessageBox.Show("Error importing library. Please try again. If this happens after 2 or 3 tries, contact administrator", "Error importing library", MessageBoxButtons.OK, MessageBoxIcon.Error);
}
this.Close();
}